(function webpackUniversalModuleDefinition(root, factory) {
	if(typeof exports === 'object' && typeof module === 'object')
		module.exports = factory();
	else if(typeof define === 'function' && define.amd)
		define([], factory);
	else if(typeof exports === 'object')
		exports["index"] = factory();
	else
		root["index"] = factory();
})((typeof self !== 'undefined' ? self : this), function() {
return /******/ (function() { // webpackBootstrap
/******/ 	"use strict";
/******/ 	var __webpack_modules__ = ({

/***/ 6218:
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  "default": function() { return /* binding */ G; }
});

// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js
var arrayLikeToArray = __webpack_require__(9796);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js

function _arrayWithoutHoles(arr) {
  if (Array.isArray(arr)) return (0,arrayLikeToArray/* default */.A)(arr);
}
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.js
var es_symbol = __webpack_require__(2675);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.description.js
var es_symbol_description = __webpack_require__(9463);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.iterator.js
var es_symbol_iterator = __webpack_require__(2259);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.from.js
var es_array_from = __webpack_require__(3418);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.to-string.js
var es_object_to_string = __webpack_require__(6099);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.iterator.js
var es_string_iterator = __webpack_require__(7764);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.iterator.js
var web_dom_collections_iterator = __webpack_require__(2953);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/iterableToArray.js







function _iterableToArray(iter) {
  if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
}
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js
var unsupportedIterableToArray = __webpack_require__(5417);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.error.cause.js
var es_error_cause = __webpack_require__(6280);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js

function _nonIterableSpread() {
  throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
}
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/toConsumableArray.js




function _toConsumableArray(arr) {
  return _arrayWithoutHoles(arr) || _iterableToArray(arr) || (0,unsupportedIterableToArray/* default */.A)(arr) || _nonIterableSpread();
}
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/regeneratorRuntime.js
var regeneratorRuntime = __webpack_require__(2946);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js
var asyncToGenerator = __webpack_require__(1362);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/callSuper.js + 3 modules
var callSuper = __webpack_require__(2934);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/inherits.js + 1 modules
var inherits = __webpack_require__(6229);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js
var classCallCheck = __webpack_require__(1512);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/createClass.js + 2 modules
var createClass = __webpack_require__(5629);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.iterator.js
var es_array_iterator = __webpack_require__(3792);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.last-index-of.js
var es_array_last_index_of = __webpack_require__(8921);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js
var es_array_push = __webpack_require__(4114);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array-buffer.slice.js
var es_array_buffer_slice = __webpack_require__(1745);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.number.constructor.js
var es_number_constructor = __webpack_require__(2892);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.keys.js
var es_object_keys = __webpack_require__(9432);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.promise.js
var es_promise = __webpack_require__(3362);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.to-string.js
var es_regexp_to_string = __webpack_require__(8781);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.float32-array.js
var es_typed_array_float32_array = __webpack_require__(4594);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.uint8-array.js
var es_typed_array_uint8_array = __webpack_require__(1489);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.at.js
var es_typed_array_at = __webpack_require__(8140);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.copy-within.js
var es_typed_array_copy_within = __webpack_require__(1630);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.every.js
var es_typed_array_every = __webpack_require__(2170);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.fill.js
var es_typed_array_fill = __webpack_require__(5044);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.filter.js
var es_typed_array_filter = __webpack_require__(1920);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.find.js
var es_typed_array_find = __webpack_require__(1694);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.find-index.js
var es_typed_array_find_index = __webpack_require__(9955);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.find-last.js
var es_typed_array_find_last = __webpack_require__(1903);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.find-last-index.js
var es_typed_array_find_last_index = __webpack_require__(1134);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.for-each.js
var es_typed_array_for_each = __webpack_require__(3206);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.includes.js
var es_typed_array_includes = __webpack_require__(4496);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.index-of.js
var es_typed_array_index_of = __webpack_require__(6651);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.iterator.js
var es_typed_array_iterator = __webpack_require__(2887);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.join.js
var es_typed_array_join = __webpack_require__(9369);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.last-index-of.js
var es_typed_array_last_index_of = __webpack_require__(6812);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.map.js
var es_typed_array_map = __webpack_require__(8995);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.reduce.js
var es_typed_array_reduce = __webpack_require__(1575);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.reduce-right.js
var es_typed_array_reduce_right = __webpack_require__(6072);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.reverse.js
var es_typed_array_reverse = __webpack_require__(8747);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.set.js
var es_typed_array_set = __webpack_require__(8845);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.slice.js
var es_typed_array_slice = __webpack_require__(9423);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.some.js
var es_typed_array_some = __webpack_require__(7301);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.sort.js
var es_typed_array_sort = __webpack_require__(373);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-locale-string.js
var es_typed_array_to_locale_string = __webpack_require__(1405);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-reversed.js
var es_typed_array_to_reversed = __webpack_require__(7467);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-sorted.js
var es_typed_array_to_sorted = __webpack_require__(4732);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-string.js
var es_typed_array_to_string = __webpack_require__(3684);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.with.js
var es_typed_array_with = __webpack_require__(9577);
// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.array-buffer.detached.js
var esnext_array_buffer_detached = __webpack_require__(3899);
// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.array-buffer.transfer.js
var esnext_array_buffer_transfer = __webpack_require__(7913);
// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.array-buffer.transfer-to-fixed-length.js
var esnext_array_buffer_transfer_to_fixed_length = __webpack_require__(7801);
// EXTERNAL MODULE: ./src/components/waifu-tips.js + 1 modules
var waifu_tips = __webpack_require__(5673);
;// CONCATENATED MODULE: ./src/components/chunk/index.js

















































/*!
 * Live2D Widget
 * https://github.com/stevenjoezhang/live2d-widget
 */

var e = /*#__PURE__*/function () {
  function e() {
    (0,classCallCheck/* default */.A)(this, e);
    this.live2DModel = null, this.modelMatrix = null, this.eyeBlink = null, this.physics = null, this.pose = null, this.initialized = !1, this.updating = !1, this.alpha = 1, this.accAlpha = 0, this.lipSync = !1, this.lipSyncValue = 0, this.accelX = 0, this.accelY = 0, this.accelZ = 0, this.dragX = 0, this.dragY = 0, this.startTimeMSec = null, this.mainMotionManager = new l(), this.expressionManager = new l(), this.motions = {}, this.expressions = {}, this.isTexLoaded = !1;
  }
  (0,createClass/* default */.A)(e, [{
    key: "getModelMatrix",
    value: function getModelMatrix() {
      return this.modelMatrix;
    }
  }, {
    key: "setAlpha",
    value: function setAlpha(t) {
      t > .999 && (t = 1), t < .001 && (t = 0), this.alpha = t;
    }
  }, {
    key: "getAlpha",
    value: function getAlpha() {
      return this.alpha;
    }
  }, {
    key: "isInitialized",
    value: function isInitialized() {
      return this.initialized;
    }
  }, {
    key: "setInitialized",
    value: function setInitialized(t) {
      this.initialized = t;
    }
  }, {
    key: "isUpdating",
    value: function isUpdating() {
      return this.updating;
    }
  }, {
    key: "setUpdating",
    value: function setUpdating(t) {
      this.updating = t;
    }
  }, {
    key: "getLive2DModel",
    value: function getLive2DModel() {
      return this.live2DModel;
    }
  }, {
    key: "setLipSync",
    value: function setLipSync(t) {
      this.lipSync = t;
    }
  }, {
    key: "setLipSyncValue",
    value: function setLipSyncValue(t) {
      this.lipSyncValue = t;
    }
  }, {
    key: "setAccel",
    value: function setAccel(t, _e, i) {
      this.accelX = t, this.accelY = _e, this.accelZ = i;
    }
  }, {
    key: "setDrag",
    value: function setDrag(t, _e2) {
      this.dragX = t, this.dragY = _e2;
    }
  }, {
    key: "getMainMotionManager",
    value: function getMainMotionManager() {
      return this.mainMotionManager;
    }
  }, {
    key: "getExpressionManager",
    value: function getExpressionManager() {
      return this.expressionManager;
    }
  }, {
    key: "loadModelData",
    value: function loadModelData(_e3, i) {
      var _this = this;
      var s = M.getPlatformManager();
      waifu_tips.l.info('Load model : ' + _e3), s.loadLive2DModel(_e3, function (_e4) {
        _this.live2DModel = _e4, _this.live2DModel.saveParam();
        0 == Live2D.getError() ? (_this.modelMatrix = new h(_this.live2DModel.getCanvasWidth(), _this.live2DModel.getCanvasHeight()), _this.modelMatrix.setWidth(window.Live2DModelConfigScale || 2), _this.modelMatrix.setCenterPosition(0, 0), i(_this.live2DModel)) : waifu_tips.l.error('Error : Failed to loadModelData().');
      });
    }
  }, {
    key: "loadTexture",
    value: function loadTexture(_e5, s, n) {
      var _this2 = this;
      i++;
      var a = M.getPlatformManager();
      waifu_tips.l.info('Load Texture : ' + s), a.loadTexture(this.live2DModel, _e5, s, function () {
        i--, 0 == i && (_this2.isTexLoaded = !0), 'function' == typeof n && n();
      });
    }
  }, {
    key: "loadMotion",
    value: function loadMotion(_e6, i, s) {
      var _this3 = this;
      var n = M.getPlatformManager();
      waifu_tips.l.trace('Load Motion : ' + i);
      var a = null;
      n.loadBytes(i, function (t) {
        a = Live2DMotion.loadMotion(t), null != _e6 && (_this3.motions[_e6] = a), s(a);
      });
    }
  }, {
    key: "loadExpression",
    value: function loadExpression(_e7, i, n) {
      var _this4 = this;
      var a = M.getPlatformManager();
      waifu_tips.l.trace('Load Expression : ' + i), a.loadBytes(i, function (t) {
        null != _e7 && (_this4.expressions[_e7] = s.loadJson(t)), 'function' == typeof n && n();
      });
    }
  }, {
    key: "loadPose",
    value: function loadPose(_e8, i) {
      var _this5 = this;
      var s = M.getPlatformManager();
      waifu_tips.l.trace('Load Pose : ' + _e8);
      try {
        s.loadBytes(_e8, function (t) {
          _this5.pose = d.load(t), 'function' == typeof i && i();
        });
      } catch (_e9) {
        waifu_tips.l.warn(_e9);
      }
    }
  }, {
    key: "loadPhysics",
    value: function loadPhysics(_e10) {
      var _this6 = this;
      var i = M.getPlatformManager();
      waifu_tips.l.trace('Load Physics : ' + _e10);
      try {
        i.loadBytes(_e10, function (t) {
          _this6.physics = c.load(t);
        });
      } catch (_e11) {
        waifu_tips.l.warn(_e11);
      }
    }
  }, {
    key: "hitTestSimple",
    value: function hitTestSimple(t, _e12, i) {
      var s = this.live2DModel.getDrawDataIndex(t);
      if (s < 0) return !1;
      var n = this.live2DModel.getTransformedPoints(s);
      var a = this.live2DModel.getCanvasWidth(),
        r = 0,
        o = this.live2DModel.getCanvasHeight(),
        h = 0;
      for (var _t = 0; _t < n.length; _t += 2) {
        var _e13 = n[_t],
          _i = n[_t + 1];
        _e13 < a && (a = _e13), _e13 > r && (r = _e13), _i < o && (o = _i), _i > h && (h = _i);
      }
      var l = this.modelMatrix.invertTransformX(_e12),
        c = this.modelMatrix.invertTransformY(i);
      return a <= l && l <= r && o <= c && c <= h;
    }
  }]);
  return e;
}();
var i = 0;
var s = /*#__PURE__*/function (_AMotion) {
  (0,inherits/* default */.A)(s, _AMotion);
  function s() {
    var _this7;
    (0,classCallCheck/* default */.A)(this, s);
    _this7 = (0,callSuper/* default */.A)(this, s), _this7.paramList = [];
    return _this7;
  }
  (0,createClass/* default */.A)(s, [{
    key: "updateParamExe",
    value: function updateParamExe(t, e, i, n) {
      for (var _e14 = this.paramList.length - 1; _e14 >= 0; --_e14) {
        var _n = this.paramList[_e14];
        _n.type == s.TYPE_ADD ? t.addToParamFloat(_n.id, _n.value, i) : _n.type == s.TYPE_MULT ? t.multParamFloat(_n.id, _n.value, i) : _n.type == s.TYPE_SET && t.setParamFloat(_n.id, _n.value, i);
      }
    }
  }], [{
    key: "loadJson",
    value: function loadJson(t) {
      var e = new s(),
        i = M.getPlatformManager().jsonParseFromBytes(t);
      if (e.setFadeIn(parseInt(i.fade_in) > 0 ? parseInt(i.fade_in) : 1e3), e.setFadeOut(parseInt(i.fade_out) > 0 ? parseInt(i.fade_out) : 1e3), null == i.params) return e;
      var a = i.params,
        r = a.length;
      e.paramList = [];
      for (var _t2 = 0; _t2 < r; _t2++) {
        var _i2 = a[_t2],
          _r = _i2.id.toString();
        var _o = parseFloat(_i2.val),
          _h = s.TYPE_ADD;
        var _l = null != _i2.calc ? _i2.calc.toString() : 'add';
        if (_h = 'add' === _l ? s.TYPE_ADD : 'mult' === _l ? s.TYPE_MULT : 'set' === _l ? s.TYPE_SET : s.TYPE_ADD, _h == s.TYPE_ADD) {
          _o -= null == _i2.def ? 0 : parseFloat(_i2.def);
        } else if (_h == s.TYPE_MULT) {
          var _t3 = null == _i2.def ? 1 : parseFloat(_i2.def);
          0 == _t3 && (_t3 = 1), _o /= _t3;
        }
        var _c = new n();
        _c.id = _r, _c.type = _h, _c.value = _o, e.paramList.push(_c);
      }
      return e;
    }
  }]);
  return s;
}(AMotion);
function n() {
  this.id = '', this.type = -1, this.value = null;
}
s.EXPRESSION_DEFAULT = 'DEFAULT', s.TYPE_SET = 0, s.TYPE_ADD = 1, s.TYPE_MULT = 2;
var a = /*#__PURE__*/function () {
  function a() {
    (0,classCallCheck/* default */.A)(this, a);
    this.nextBlinkTime = null, this.stateStartTime = null, this.blinkIntervalMsec = null, this.eyeState = r.STATE_FIRST, this.blinkIntervalMsec = 4e3, this.closingMotionMsec = 100, this.closedMotionMsec = 50, this.openingMotionMsec = 150, this.closeIfZero = !0, this.eyeID_L = 'PARAM_EYE_L_OPEN', this.eyeID_R = 'PARAM_EYE_R_OPEN';
  }
  (0,createClass/* default */.A)(a, [{
    key: "calcNextBlink",
    value: function calcNextBlink() {
      return UtSystem.getUserTimeMSec() + Math.random() * (2 * this.blinkIntervalMsec - 1);
    }
  }, {
    key: "setInterval",
    value: function setInterval(t) {
      this.blinkIntervalMsec = t;
    }
  }, {
    key: "setEyeMotion",
    value: function setEyeMotion(t, e, i) {
      this.closingMotionMsec = t, this.closedMotionMsec = e, this.openingMotionMsec = i;
    }
  }, {
    key: "updateParam",
    value: function updateParam(t) {
      var e = UtSystem.getUserTimeMSec();
      var i,
        s = 0;
      switch (this.eyeState) {
        case r.STATE_CLOSING:
          s = (e - this.stateStartTime) / this.closingMotionMsec, s >= 1 && (s = 1, this.eyeState = r.STATE_CLOSED, this.stateStartTime = e), i = 1 - s;
          break;
        case r.STATE_CLOSED:
          s = (e - this.stateStartTime) / this.closedMotionMsec, s >= 1 && (this.eyeState = r.STATE_OPENING, this.stateStartTime = e), i = 0;
          break;
        case r.STATE_OPENING:
          s = (e - this.stateStartTime) / this.openingMotionMsec, s >= 1 && (s = 1, this.eyeState = r.STATE_INTERVAL, this.nextBlinkTime = this.calcNextBlink()), i = s;
          break;
        case r.STATE_INTERVAL:
          this.nextBlinkTime < e && (this.eyeState = r.STATE_CLOSING, this.stateStartTime = e), i = 1;
          break;
        case r.STATE_FIRST:
        default:
          this.eyeState = r.STATE_INTERVAL, this.nextBlinkTime = this.calcNextBlink(), i = 1;
      }
      this.closeIfZero || (i = -i), t.setParamFloat(this.eyeID_L, i), t.setParamFloat(this.eyeID_R, i);
    }
  }]);
  return a;
}();
var r = function r() {};
r.STATE_FIRST = 'STATE_FIRST', r.STATE_INTERVAL = 'STATE_INTERVAL', r.STATE_CLOSING = 'STATE_CLOSING', r.STATE_CLOSED = 'STATE_CLOSED', r.STATE_OPENING = 'STATE_OPENING';
var o = /*#__PURE__*/function () {
  function o() {
    (0,classCallCheck/* default */.A)(this, o);
    this.tr = new Float32Array(16), this.identity();
  }
  (0,createClass/* default */.A)(o, [{
    key: "identity",
    value: function identity() {
      for (var _t4 = 0; _t4 < 16; _t4++) this.tr[_t4] = _t4 % 5 == 0 ? 1 : 0;
    }
  }, {
    key: "getArray",
    value: function getArray() {
      return this.tr;
    }
  }, {
    key: "getCopyMatrix",
    value: function getCopyMatrix() {
      return new Float32Array(this.tr);
    }
  }, {
    key: "setMatrix",
    value: function setMatrix(t) {
      if (null != this.tr && this.tr.length == this.tr.length) for (var _e15 = 0; _e15 < 16; _e15++) this.tr[_e15] = t[_e15];
    }
  }, {
    key: "getScaleX",
    value: function getScaleX() {
      return this.tr[0];
    }
  }, {
    key: "getScaleY",
    value: function getScaleY() {
      return this.tr[5];
    }
  }, {
    key: "transformX",
    value: function transformX(t) {
      return this.tr[0] * t + this.tr[12];
    }
  }, {
    key: "transformY",
    value: function transformY(t) {
      return this.tr[5] * t + this.tr[13];
    }
  }, {
    key: "invertTransformX",
    value: function invertTransformX(t) {
      return (t - this.tr[12]) / this.tr[0];
    }
  }, {
    key: "invertTransformY",
    value: function invertTransformY(t) {
      return (t - this.tr[13]) / this.tr[5];
    }
  }, {
    key: "multTranslate",
    value: function multTranslate(t, e) {
      var i = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, t, e, 0, 1];
      o.mul(i, this.tr, this.tr);
    }
  }, {
    key: "translate",
    value: function translate(t, e) {
      this.tr[12] = t, this.tr[13] = e;
    }
  }, {
    key: "translateX",
    value: function translateX(t) {
      this.tr[12] = t;
    }
  }, {
    key: "translateY",
    value: function translateY(t) {
      this.tr[13] = t;
    }
  }, {
    key: "multScale",
    value: function multScale(t, e) {
      var i = [t, 0, 0, 0, 0, e, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1];
      o.mul(i, this.tr, this.tr);
    }
  }, {
    key: "scale",
    value: function scale(t, e) {
      this.tr[0] = t, this.tr[5] = e;
    }
  }], [{
    key: "mul",
    value: function mul(t, e, i) {
      var s = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
      var n, a, r;
      for (n = 0; n < 4; n++) for (a = 0; a < 4; a++) for (r = 0; r < 4; r++) s[n + 4 * a] += t[n + 4 * r] * e[r + 4 * a];
      for (n = 0; n < 16; n++) i[n] = s[n];
    }
  }]);
  return o;
}();
var h = /*#__PURE__*/function (_o2) {
  (0,inherits/* default */.A)(h, _o2);
  function h(t, e) {
    var _this8;
    (0,classCallCheck/* default */.A)(this, h);
    _this8 = (0,callSuper/* default */.A)(this, h), _this8.width = t, _this8.height = e;
    return _this8;
  }
  (0,createClass/* default */.A)(h, [{
    key: "setPosition",
    value: function setPosition(t, e) {
      this.translate(t, e);
    }
  }, {
    key: "setCenterPosition",
    value: function setCenterPosition(t, e) {
      var i = this.width * this.getScaleX(),
        s = this.height * this.getScaleY();
      this.translate(t - i / 2, e - s / 2);
    }
  }, {
    key: "top",
    value: function top(t) {
      this.setY(t);
    }
  }, {
    key: "bottom",
    value: function bottom(t) {
      var e = this.height * this.getScaleY();
      this.translateY(t - e);
    }
  }, {
    key: "left",
    value: function left(t) {
      this.setX(t);
    }
  }, {
    key: "right",
    value: function right(t) {
      var e = this.width * this.getScaleX();
      this.translateX(t - e);
    }
  }, {
    key: "centerX",
    value: function centerX(t) {
      var e = this.width * this.getScaleX();
      this.translateX(t - e / 2);
    }
  }, {
    key: "centerY",
    value: function centerY(t) {
      var e = this.height * this.getScaleY();
      this.translateY(t - e / 2);
    }
  }, {
    key: "setX",
    value: function setX(t) {
      this.translateX(t);
    }
  }, {
    key: "setY",
    value: function setY(t) {
      this.translateY(t);
    }
  }, {
    key: "setHeight",
    value: function setHeight(t) {
      var e = t / this.height,
        i = -e;
      this.scale(e, i);
    }
  }, {
    key: "setWidth",
    value: function setWidth(t) {
      var e = t / this.width,
        i = -e;
      this.scale(e, i);
    }
  }]);
  return h;
}(o);
var l = /*#__PURE__*/function (_MotionQueueManager) {
  (0,inherits/* default */.A)(l, _MotionQueueManager);
  function l() {
    var _this9;
    (0,classCallCheck/* default */.A)(this, l);
    _this9 = (0,callSuper/* default */.A)(this, l), _this9.currentPriority = null, _this9.reservePriority = null, _this9.super = MotionQueueManager.prototype;
    return _this9;
  }
  (0,createClass/* default */.A)(l, [{
    key: "getCurrentPriority",
    value: function getCurrentPriority() {
      return this.currentPriority;
    }
  }, {
    key: "getReservePriority",
    value: function getReservePriority() {
      return this.reservePriority;
    }
  }, {
    key: "reserveMotion",
    value: function reserveMotion(t) {
      return !(this.reservePriority >= t) && !(this.currentPriority >= t) && (this.reservePriority = t, !0);
    }
  }, {
    key: "setReservePriority",
    value: function setReservePriority(t) {
      this.reservePriority = t;
    }
  }, {
    key: "updateParam",
    value: function updateParam(t) {
      var e = MotionQueueManager.prototype.updateParam.call(this, t);
      return this.isFinished() && (this.currentPriority = 0), e;
    }
  }, {
    key: "startMotionPrio",
    value: function startMotionPrio(t, e) {
      return e == this.reservePriority && (this.reservePriority = 0), this.currentPriority = e, this.startMotion(t, !1);
    }
  }]);
  return l;
}(MotionQueueManager);
var c = /*#__PURE__*/function () {
  function c() {
    (0,classCallCheck/* default */.A)(this, c);
    this.physicsList = [], this.startTimeMSec = UtSystem.getUserTimeMSec();
  }
  (0,createClass/* default */.A)(c, [{
    key: "updateParam",
    value: function updateParam(t) {
      var e = UtSystem.getUserTimeMSec() - this.startTimeMSec;
      for (var _i3 = 0; _i3 < this.physicsList.length; _i3++) this.physicsList[_i3].update(t, e);
    }
  }], [{
    key: "load",
    value: function load(t) {
      var e = new c(),
        i = M.getPlatformManager().jsonParseFromBytes(t).physics_hair,
        s = i.length;
      for (var _t5 = 0; _t5 < s; _t5++) {
        var _s = i[_t5],
          _n2 = new PhysicsHair(),
          _a = _s.setup,
          _r2 = parseFloat(_a.length),
          _o3 = parseFloat(_a.regist),
          _h2 = parseFloat(_a.mass);
        _n2.setup(_r2, _o3, _h2);
        var _l2 = _s.src,
          _c2 = _l2.length;
        for (var _t6 = 0; _t6 < _c2; _t6++) {
          var _e16 = _l2[_t6];
          var _i4 = _e16.id,
            _s2 = PhysicsHair.Src.SRC_TO_X,
            _a2 = _e16.ptype;
          'x' === _a2 ? _s2 = PhysicsHair.Src.SRC_TO_X : 'y' === _a2 ? _s2 = PhysicsHair.Src.SRC_TO_Y : 'angle' === _a2 ? _s2 = PhysicsHair.Src.SRC_TO_G_ANGLE : UtDebug.error('live2d', 'Invalid parameter:PhysicsHair.Src');
          var _r3 = parseFloat(_e16.scale),
            _o4 = parseFloat(_e16.weight);
          _n2.addSrcParam(_s2, _i4, _r3, _o4);
        }
        var _d = _s.targets,
          _u = _d.length;
        for (var _t7 = 0; _t7 < _u; _t7++) {
          var _e17 = _d[_t7];
          var _i5 = _e17.id,
            _s3 = PhysicsHair.Target.TARGET_FROM_ANGLE,
            _a3 = _e17.ptype;
          'angle' === _a3 ? _s3 = PhysicsHair.Target.TARGET_FROM_ANGLE : 'angle_v' === _a3 ? _s3 = PhysicsHair.Target.TARGET_FROM_ANGLE_V : UtDebug.error('live2d', 'Invalid parameter:PhysicsHair.Target');
          var _r4 = parseFloat(_e17.scale),
            _o5 = parseFloat(_e17.weight);
          _n2.addTargetParam(_s3, _i5, _r4, _o5);
        }
        e.physicsList.push(_n2);
      }
      return e;
    }
  }]);
  return c;
}();
var d = /*#__PURE__*/function () {
  function d() {
    (0,classCallCheck/* default */.A)(this, d);
    this.lastTime = 0, this.lastModel = null, this.partsGroups = [];
  }
  (0,createClass/* default */.A)(d, [{
    key: "updateParam",
    value: function updateParam(t) {
      if (null == t) return;
      t != this.lastModel && this.initParam(t), this.lastModel = t;
      var e = UtSystem.getUserTimeMSec();
      var i = 0 == this.lastTime ? 0 : (e - this.lastTime) / 1e3;
      this.lastTime = e, i < 0 && (i = 0);
      for (var _e18 = 0; _e18 < this.partsGroups.length; _e18++) this.normalizePartsOpacityGroup(t, this.partsGroups[_e18], i), this.copyOpacityOtherParts(t, this.partsGroups[_e18]);
    }
  }, {
    key: "initParam",
    value: function initParam(t) {
      if (null != t) {
        for (var _e19 = 0; _e19 < this.partsGroups.length; _e19++) {
          var _i6 = this.partsGroups[_e19];
          for (var _e20 = 0; _e20 < _i6.length; _e20++) {
            _i6[_e20].initIndex(t);
            var _s4 = _i6[_e20].partsIndex,
              _n3 = _i6[_e20].paramIndex;
            if (_s4 < 0) continue;
            var _a4 = 0 != t.getParamFloat(_n3);
            if (t.setPartsOpacity(_s4, _a4 ? 1 : 0), t.setParamFloat(_n3, _a4 ? 1 : 0), null != _i6[_e20].link) for (var _s5 = 0; _s5 < _i6[_e20].link.length; _s5++) _i6[_e20].link[_s5].initIndex(t);
          }
        }
      }
    }
  }, {
    key: "normalizePartsOpacityGroup",
    value: function normalizePartsOpacityGroup(t, e, i) {
      var s = -1,
        n = 1;
      var a = .5;
      for (var _a5 = 0; _a5 < e.length; _a5++) {
        var _r5 = e[_a5].partsIndex;
        var _o6 = e[_a5].paramIndex;
        if (!(_r5 < 0) && 0 != t.getParamFloat(_o6)) {
          if (s >= 0) break;
          s = _a5, n = t.getPartsOpacity(_r5), n += i / .5, n > 1 && (n = 1);
        }
      }
      s < 0 && (s = 0, n = 1);
      for (var _i7 = 0; _i7 < e.length; _i7++) {
        var _r6 = e[_i7].partsIndex;
        if (!(_r6 < 0)) {
          if (s == _i7) {
            t.setPartsOpacity(_r6, n);
          } else {
            var _e21 = void 0,
              _i8 = t.getPartsOpacity(_r6);
            _e21 = n < a ? -.5 * n / a + 1 : (1 - n) * a / .5;
            (1 - _e21) * (1 - n) > .15 && (_e21 = 1 - .15 / (1 - n)), _i8 > _e21 && (_i8 = _e21), t.setPartsOpacity(_r6, _i8);
          }
        }
      }
    }
  }, {
    key: "copyOpacityOtherParts",
    value: function copyOpacityOtherParts(t, e) {
      for (var _i9 = 0; _i9 < e.length; _i9++) {
        var _s6 = e[_i9];
        if (null == _s6.link) continue;
        if (_s6.partsIndex < 0) continue;
        var _n4 = t.getPartsOpacity(_s6.partsIndex);
        for (var _e22 = 0; _e22 < _s6.link.length; _e22++) {
          var _i10 = _s6.link[_e22];
          _i10.partsIndex < 0 || t.setPartsOpacity(_i10.partsIndex, _n4);
        }
      }
    }
  }], [{
    key: "load",
    value: function load(t) {
      var e = new d(),
        i = M.getPlatformManager().jsonParseFromBytes(t).parts_visible,
        s = i.length;
      for (var _t8 = 0; _t8 < s; _t8++) {
        var _s7 = i[_t8].group,
          _n5 = _s7.length,
          _a6 = [];
        for (var _t9 = 0; _t9 < _n5; _t9++) {
          var _e23 = _s7[_t9],
            _i11 = new u(_e23.id);
          if (_a6[_t9] = _i11, null == _e23.link) continue;
          var _n6 = _e23.link,
            _r7 = _n6.length;
          _i11.link = [];
          for (var _t10 = 0; _t10 < _r7; _t10++) {
            var _e24 = new u(_n6[_t10]);
            _i11.link.push(_e24);
          }
        }
        e.partsGroups.push(_a6);
      }
      return e;
    }
  }]);
  return d;
}();
var u = /*#__PURE__*/function () {
  function u(t) {
    (0,classCallCheck/* default */.A)(this, u);
    this.paramIndex = -1, this.partsIndex = -1, this.link = null, this.id = t;
  }
  (0,createClass/* default */.A)(u, [{
    key: "initIndex",
    value: function initIndex(t) {
      this.paramIndex = t.getParamIndex('VISIBLE:' + this.id), this.partsIndex = t.getPartsDataIndex(PartsDataID.getID(this.id)), t.setParamFloat(this.paramIndex, 1);
    }
  }]);
  return u;
}();
var m = /*#__PURE__*/function () {
  function m() {
    (0,classCallCheck/* default */.A)(this, m);
    this.EPSILON = .01, this.faceTargetX = 0, this.faceTargetY = 0, this.faceX = 0, this.faceY = 0, this.faceVX = 0, this.faceVY = 0, this.lastTimeSec = 0;
  }
  (0,createClass/* default */.A)(m, [{
    key: "setPoint",
    value: function setPoint(t, e) {
      this.faceTargetX = t, this.faceTargetY = e;
    }
  }, {
    key: "getX",
    value: function getX() {
      return this.faceX;
    }
  }, {
    key: "getY",
    value: function getY() {
      return this.faceY;
    }
  }, {
    key: "update",
    value: function update() {
      var t = 40 / 7.5 / m.FRAME_RATE;
      if (0 == this.lastTimeSec) return void (this.lastTimeSec = UtSystem.getUserTimeMSec());
      var e = UtSystem.getUserTimeMSec(),
        i = (e - this.lastTimeSec) * m.FRAME_RATE / 1e3;
      this.lastTimeSec = e;
      var s = i * t / (.15 * m.FRAME_RATE),
        n = this.faceTargetX - this.faceX,
        a = this.faceTargetY - this.faceY;
      if (Math.abs(n) <= this.EPSILON && Math.abs(a) <= this.EPSILON) return;
      var r = Math.sqrt(n * n + a * a),
        o = t * a / r;
      var h = t * n / r - this.faceVX,
        l = o - this.faceVY,
        c = Math.sqrt(h * h + l * l);
      (c < -s || c > s) && (h *= s / c, l *= s / c, c = s), this.faceVX += h, this.faceVY += l;
      {
        var _t11 = .5 * (Math.sqrt(s * s + 16 * s * r - 8 * s * r) - s),
          _e25 = Math.sqrt(this.faceVX * this.faceVX + this.faceVY * this.faceVY);
        _e25 > _t11 && (this.faceVX *= _t11 / _e25, this.faceVY *= _t11 / _e25);
      }
      this.faceX += this.faceVX, this.faceY += this.faceVY;
    }
  }]);
  return m;
}();
m.FRAME_RATE = 30;
var g = /*#__PURE__*/function (_o7) {
  (0,inherits/* default */.A)(g, _o7);
  function g() {
    var _this10;
    (0,classCallCheck/* default */.A)(this, g);
    _this10 = (0,callSuper/* default */.A)(this, g), _this10.screenLeft = null, _this10.screenRight = null, _this10.screenTop = null, _this10.screenBottom = null, _this10.maxLeft = null, _this10.maxRight = null, _this10.maxTop = null, _this10.maxBottom = null, _this10.max = Number.MAX_VALUE, _this10.min = 0;
    return _this10;
  }
  (0,createClass/* default */.A)(g, [{
    key: "getMaxScale",
    value: function getMaxScale() {
      return this.max;
    }
  }, {
    key: "getMinScale",
    value: function getMinScale() {
      return this.min;
    }
  }, {
    key: "setMaxScale",
    value: function setMaxScale(t) {
      this.max = t;
    }
  }, {
    key: "setMinScale",
    value: function setMinScale(t) {
      this.min = t;
    }
  }, {
    key: "isMaxScale",
    value: function isMaxScale() {
      return this.getScaleX() == this.max;
    }
  }, {
    key: "isMinScale",
    value: function isMinScale() {
      return this.getScaleX() == this.min;
    }
  }, {
    key: "adjustTranslate",
    value: function adjustTranslate(t, e) {
      this.tr[0] * this.maxLeft + (this.tr[12] + t) > this.screenLeft && (t = this.screenLeft - this.tr[0] * this.maxLeft - this.tr[12]), this.tr[0] * this.maxRight + (this.tr[12] + t) < this.screenRight && (t = this.screenRight - this.tr[0] * this.maxRight - this.tr[12]), this.tr[5] * this.maxTop + (this.tr[13] + e) < this.screenTop && (e = this.screenTop - this.tr[5] * this.maxTop - this.tr[13]), this.tr[5] * this.maxBottom + (this.tr[13] + e) > this.screenBottom && (e = this.screenBottom - this.tr[5] * this.maxBottom - this.tr[13]);
      var i = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, t, e, 0, 1];
      o.mul(i, this.tr, this.tr);
    }
  }, {
    key: "adjustScale",
    value: function adjustScale(t, e, i) {
      var s = i * this.tr[0];
      s < this.min ? this.tr[0] > 0 && (i = this.min / this.tr[0]) : s > this.max && this.tr[0] > 0 && (i = this.max / this.tr[0]);
      var n = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, t, e, 0, 1],
        a = [i, 0, 0, 0, 0, i, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1],
        r = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, -t, -e, 0, 1];
      o.mul(r, this.tr, this.tr), o.mul(a, this.tr, this.tr), o.mul(n, this.tr, this.tr);
    }
  }, {
    key: "setScreenRect",
    value: function setScreenRect(t, e, i, s) {
      this.screenLeft = t, this.screenRight = e, this.screenTop = s, this.screenBottom = i;
    }
  }, {
    key: "setMaxScreenRect",
    value: function setMaxScreenRect(t, e, i, s) {
      this.maxLeft = t, this.maxRight = e, this.maxTop = s, this.maxBottom = i;
    }
  }, {
    key: "getScreenLeft",
    value: function getScreenLeft() {
      return this.screenLeft;
    }
  }, {
    key: "getScreenRight",
    value: function getScreenRight() {
      return this.screenRight;
    }
  }, {
    key: "getScreenBottom",
    value: function getScreenBottom() {
      return this.screenBottom;
    }
  }, {
    key: "getScreenTop",
    value: function getScreenTop() {
      return this.screenTop;
    }
  }, {
    key: "getMaxLeft",
    value: function getMaxLeft() {
      return this.maxLeft;
    }
  }, {
    key: "getMaxRight",
    value: function getMaxRight() {
      return this.maxRight;
    }
  }, {
    key: "getMaxBottom",
    value: function getMaxBottom() {
      return this.maxBottom;
    }
  }, {
    key: "getMaxTop",
    value: function getMaxTop() {
      return this.maxTop;
    }
  }]);
  return g;
}(o);
var M = /*#__PURE__*/function () {
  function M() {
    (0,classCallCheck/* default */.A)(this, M);
  }
  (0,createClass/* default */.A)(M, null, [{
    key: "getPlatformManager",
    value: function getPlatformManager() {
      return M.platformManager;
    }
  }, {
    key: "setPlatformManager",
    value: function setPlatformManager(t) {
      M.platformManager = t;
    }
  }]);
  return M;
}();
M.platformManager = null;
var S = 2,
  T = .8,
  p = -1,
  E = 1,
  v = -2,
  P = 2,
  _ = -2,
  I = 2,
  x = 1,
  f = 2,
  A = 3,
  y = 'idle',
  R = 'tap_body',
  O = 'pinch_in',
  D = 'pinch_out',
  L = 'head',
  N = 'body';
var w = /*#__PURE__*/function () {
  function w() {
    (0,classCallCheck/* default */.A)(this, w);
  }
  (0,createClass/* default */.A)(w, null, [{
    key: "reset",
    value: function reset() {
      this.depth = 0;
    }
  }, {
    key: "loadIdentity",
    value: function loadIdentity() {
      for (var _t12 = 0; _t12 < 16; _t12++) this.currentMatrix[_t12] = _t12 % 5 == 0 ? 1 : 0;
    }
  }, {
    key: "push",
    value: function push() {
      this.depth;
      var t = 16 * (this.depth + 1);
      this.matrixStack.length < t + 16 && (this.matrixStack.length = t + 16);
      for (var _e26 = 0; _e26 < 16; _e26++) this.matrixStack[t + _e26] = this.currentMatrix[_e26];
      this.depth++;
    }
  }, {
    key: "pop",
    value: function pop() {
      this.depth--, this.depth < 0 && (this.depth = 0);
      var t = 16 * this.depth;
      for (var _e27 = 0; _e27 < 16; _e27++) this.currentMatrix[_e27] = this.matrixStack[t + _e27];
    }
  }, {
    key: "getMatrix",
    value: function getMatrix() {
      return this.currentMatrix;
    }
  }, {
    key: "multMatrix",
    value: function multMatrix(t) {
      var e, i, s;
      for (e = 0; e < 16; e++) this.tmp[e] = 0;
      for (e = 0; e < 4; e++) for (i = 0; i < 4; i++) for (s = 0; s < 4; s++) this.tmp[e + 4 * i] += this.currentMatrix[e + 4 * s] * t[s + 4 * i];
      for (e = 0; e < 16; e++) this.currentMatrix[e] = this.tmp[e];
    }
  }]);
  return w;
}();
w.matrixStack = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1], w.depth = 0, w.currentMatrix = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1], w.tmp = new Array(16);
var F = /*#__PURE__*/function () {
  function F() {
    (0,classCallCheck/* default */.A)(this, F);
    this.NAME = 'name', this.ID = 'id', this.MODEL = 'model', this.TEXTURES = 'textures', this.HIT_AREAS = 'hit_areas', this.HIT_AREAS_CUSTOM = 'hit_areas_custom', this.PHYSICS = 'physics', this.POSE = 'pose', this.EXPRESSIONS = 'expressions', this.MOTION_GROUPS = 'motions', this.SOUND = 'sound', this.FADE_IN = 'fade_in', this.FADE_OUT = 'fade_out', this.LAYOUT = 'layout', this.INIT_PARAM = 'init_param', this.INIT_PARTS_VISIBLE = 'init_parts_visible', this.VALUE = 'val', this.FILE = 'file', this.json = {};
  }
  (0,createClass/* default */.A)(F, [{
    key: "loadModelSetting",
    value: function loadModelSetting(t, e) {
      var _this11 = this;
      M.getPlatformManager().loadBytes(t, function (t) {
        var i = String.fromCharCode.apply(null, new Uint8Array(t));
        _this11.json = JSON.parse(i), e();
      });
    }
  }, {
    key: "getTextureFile",
    value: function getTextureFile(t) {
      return null == this.json[this.TEXTURES] || null == this.json[this.TEXTURES][t] ? null : this.json[this.TEXTURES][t];
    }
  }, {
    key: "getModelFile",
    value: function getModelFile() {
      return this.json[this.MODEL];
    }
  }, {
    key: "getTextureNum",
    value: function getTextureNum() {
      return null == this.json[this.TEXTURES] ? 0 : this.json[this.TEXTURES].length;
    }
  }, {
    key: "getHitAreaNum",
    value: function getHitAreaNum() {
      return null == this.json[this.HIT_AREAS] ? 0 : this.json[this.HIT_AREAS].length;
    }
  }, {
    key: "getHitAreaCustom",
    value: function getHitAreaCustom() {
      return this.json[this.HIT_AREAS_CUSTOM];
    }
  }, {
    key: "getHitAreaID",
    value: function getHitAreaID(t) {
      return null == this.json[this.HIT_AREAS] || null == this.json[this.HIT_AREAS][t] ? null : this.json[this.HIT_AREAS][t][this.ID];
    }
  }, {
    key: "getHitAreaName",
    value: function getHitAreaName(t) {
      return null == this.json[this.HIT_AREAS] || null == this.json[this.HIT_AREAS][t] ? null : this.json[this.HIT_AREAS][t][this.NAME];
    }
  }, {
    key: "getPhysicsFile",
    value: function getPhysicsFile() {
      return this.json[this.PHYSICS];
    }
  }, {
    key: "getPoseFile",
    value: function getPoseFile() {
      return this.json[this.POSE];
    }
  }, {
    key: "getExpressionNum",
    value: function getExpressionNum() {
      return null == this.json[this.EXPRESSIONS] ? 0 : this.json[this.EXPRESSIONS].length;
    }
  }, {
    key: "getExpressionFile",
    value: function getExpressionFile(t) {
      return null == this.json[this.EXPRESSIONS] ? null : this.json[this.EXPRESSIONS][t][this.FILE];
    }
  }, {
    key: "getExpressionName",
    value: function getExpressionName(t) {
      return null == this.json[this.EXPRESSIONS] ? null : this.json[this.EXPRESSIONS][t][this.NAME];
    }
  }, {
    key: "getLayout",
    value: function getLayout() {
      return this.json[this.LAYOUT];
    }
  }, {
    key: "getInitParamNum",
    value: function getInitParamNum() {
      return null == this.json[this.INIT_PARAM] ? 0 : this.json[this.INIT_PARAM].length;
    }
  }, {
    key: "getMotionNum",
    value: function getMotionNum(t) {
      return null == this.json[this.MOTION_GROUPS] || null == this.json[this.MOTION_GROUPS][t] ? 0 : this.json[this.MOTION_GROUPS][t].length;
    }
  }, {
    key: "getMotionFile",
    value: function getMotionFile(t, e) {
      return null == this.json[this.MOTION_GROUPS] || null == this.json[this.MOTION_GROUPS][t] || null == this.json[this.MOTION_GROUPS][t][e] ? null : this.json[this.MOTION_GROUPS][t][e][this.FILE];
    }
  }, {
    key: "getMotionSound",
    value: function getMotionSound(t, e) {
      return null == this.json[this.MOTION_GROUPS] || null == this.json[this.MOTION_GROUPS][t] || null == this.json[this.MOTION_GROUPS][t][e] || null == this.json[this.MOTION_GROUPS][t][e][this.SOUND] ? null : this.json[this.MOTION_GROUPS][t][e][this.SOUND];
    }
  }, {
    key: "getMotionFadeIn",
    value: function getMotionFadeIn(t, e) {
      return null == this.json[this.MOTION_GROUPS] || null == this.json[this.MOTION_GROUPS][t] || null == this.json[this.MOTION_GROUPS][t][e] || null == this.json[this.MOTION_GROUPS][t][e][this.FADE_IN] ? 1e3 : this.json[this.MOTION_GROUPS][t][e][this.FADE_IN];
    }
  }, {
    key: "getMotionFadeOut",
    value: function getMotionFadeOut(t, e) {
      return null == this.json[this.MOTION_GROUPS] || null == this.json[this.MOTION_GROUPS][t] || null == this.json[this.MOTION_GROUPS][t][e] || null == this.json[this.MOTION_GROUPS][t][e][this.FADE_OUT] ? 1e3 : this.json[this.MOTION_GROUPS][t][e][this.FADE_OUT];
    }
  }, {
    key: "getInitParamID",
    value: function getInitParamID(t) {
      return null == this.json[this.INIT_PARAM] || null == this.json[this.INIT_PARAM][t] ? null : this.json[this.INIT_PARAM][t][this.ID];
    }
  }, {
    key: "getInitParamValue",
    value: function getInitParamValue(t) {
      return null == this.json[this.INIT_PARAM] || null == this.json[this.INIT_PARAM][t] ? NaN : this.json[this.INIT_PARAM][t][this.VALUE];
    }
  }, {
    key: "getInitPartsVisibleNum",
    value: function getInitPartsVisibleNum() {
      return null == this.json[this.INIT_PARTS_VISIBLE] ? 0 : this.json[this.INIT_PARTS_VISIBLE].length;
    }
  }, {
    key: "getInitPartsVisibleID",
    value: function getInitPartsVisibleID(t) {
      return null == this.json[this.INIT_PARTS_VISIBLE] || null == this.json[this.INIT_PARTS_VISIBLE][t] ? null : this.json[this.INIT_PARTS_VISIBLE][t][this.ID];
    }
  }, {
    key: "getInitPartsVisibleValue",
    value: function getInitPartsVisibleValue(t) {
      return null == this.json[this.INIT_PARTS_VISIBLE] || null == this.json[this.INIT_PARTS_VISIBLE][t] ? NaN : this.json[this.INIT_PARTS_VISIBLE][t][this.VALUE];
    }
  }]);
  return F;
}();
var U = /*#__PURE__*/function (_e28) {
  (0,inherits/* default */.A)(U, _e28);
  function U() {
    var _this12;
    (0,classCallCheck/* default */.A)(this, U);
    _this12 = (0,callSuper/* default */.A)(this, U), _this12.modelHomeDir = '', _this12.modelSetting = null, _this12.tmpMatrix = [];
    return _this12;
  }
  (0,createClass/* default */.A)(U, [{
    key: "loadJSON",
    value: function loadJSON(t) {
      var _this13 = this;
      var e = this.modelHomeDir + this.modelSetting.getModelFile();
      this.loadModelData(e, function (e) {
        for (var _e29 = 0; _e29 < _this13.modelSetting.getTextureNum(); _e29++) {
          var _i12 = _this13.modelHomeDir + _this13.modelSetting.getTextureFile(_e29);
          _this13.loadTexture(_e29, _i12, function () {
            if (_this13.isTexLoaded) {
              if (_this13.modelSetting.getExpressionNum() > 0) {
                _this13.expressions = {};
                for (var _t13 = 0; _t13 < _this13.modelSetting.getExpressionNum(); _t13++) {
                  var _e30 = _this13.modelSetting.getExpressionName(_t13),
                    _i13 = _this13.modelHomeDir + _this13.modelSetting.getExpressionFile(_t13);
                  _this13.loadExpression(_e30, _i13);
                }
              } else {
                _this13.expressionManager = null, _this13.expressions = {};
              }
              if (null == _this13.eyeBlink && (_this13.eyeBlink = new a()), null != _this13.modelSetting.getPhysicsFile() ? _this13.loadPhysics(_this13.modelHomeDir + _this13.modelSetting.getPhysicsFile()) : _this13.physics = null, null != _this13.modelSetting.getPoseFile() ? _this13.loadPose(_this13.modelHomeDir + _this13.modelSetting.getPoseFile(), function () {
                _this13.pose.updateParam(_this13.live2DModel);
              }) : _this13.pose = null, null != _this13.modelSetting.getLayout()) {
                var _t14 = _this13.modelSetting.getLayout();
                null != _t14.width && _this13.modelMatrix.setWidth(window.Live2DModelConfigScale || _t14.width), null != _t14.height && _this13.modelMatrix.setHeight(_t14.height), null != _t14.x && _this13.modelMatrix.setX(_t14.x), null != _t14.y && _this13.modelMatrix.setY(_t14.y), null != _t14.center_x && _this13.modelMatrix.centerX(_t14.center_x), null != _t14.center_y && _this13.modelMatrix.centerY(_t14.center_y), null != _t14.top && _this13.modelMatrix.top(_t14.top), null != _t14.bottom && _this13.modelMatrix.bottom(_t14.bottom), null != _t14.left && _this13.modelMatrix.left(_t14.left), null != _t14.right && _this13.modelMatrix.right(_t14.right);
              }
              for (var _t15 = 0; _t15 < _this13.modelSetting.getInitParamNum(); _t15++) _this13.live2DModel.setParamFloat(_this13.modelSetting.getInitParamID(_t15), _this13.modelSetting.getInitParamValue(_t15));
              for (var _t16 = 0; _t16 < _this13.modelSetting.getInitPartsVisibleNum(); _t16++) _this13.live2DModel.setPartsOpacity(_this13.modelSetting.getInitPartsVisibleID(_t16), _this13.modelSetting.getInitPartsVisibleValue(_t16));
              _this13.live2DModel.saveParam(), _this13.preloadMotionGroup(y), _this13.mainMotionManager.stopAllMotions(), _this13.setUpdating(!1), _this13.setInitialized(!0), 'function' == typeof t && t();
            }
          });
        }
      });
    }
  }, {
    key: "loadModelSetting",
    value: function () {
      var _loadModelSetting = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee(t, e) {
        var _this14 = this;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee$(_context) {
          while (1) switch (_context.prev = _context.next) {
            case 0:
              window.Live2DModelConfigScale = e.scale || 2;
              this.setUpdating(!0);
              this.setInitialized(!1);
              this.modelHomeDir = t.substring(0, t.lastIndexOf('/') + 1);
              this.modelSetting = new F();
              this.modelSetting.json = e;
              _context.next = 8;
              return new Promise(function (t) {
                return _this14.loadJSON(t);
              });
            case 8:
            case "end":
              return _context.stop();
          }
        }, _callee, this);
      }));
      function loadModelSetting(_x, _x2) {
        return _loadModelSetting.apply(this, arguments);
      }
      return loadModelSetting;
    }()
  }, {
    key: "load",
    value: function load(t, e, i) {
      var _this15 = this;
      this.setUpdating(!0), this.setInitialized(!1), this.modelHomeDir = e.substring(0, e.lastIndexOf('/') + 1), this.modelSetting = new F(), this.modelSetting.loadModelSetting(e, function () {
        _this15.loadJSON(i);
      });
    }
  }, {
    key: "release",
    value: function release(t) {
      var e = M.getPlatformManager();
      t.deleteTexture(e.texture);
    }
  }, {
    key: "preloadMotionGroup",
    value: function preloadMotionGroup(t) {
      var _this16 = this;
      var _loop = function _loop(_e31) {
        var i = _this16.modelSetting.getMotionFile(t, _e31);
        _this16.loadMotion(i, _this16.modelHomeDir + i, function (i) {
          i.setFadeIn(_this16.modelSetting.getMotionFadeIn(t, _e31)), i.setFadeOut(_this16.modelSetting.getMotionFadeOut(t, _e31));
        });
      };
      for (var _e31 = 0; _e31 < this.modelSetting.getMotionNum(t); _e31++) {
        _loop(_e31);
      }
    }
  }, {
    key: "update",
    value: function update() {
      if (null == this.live2DModel) return void waifu_tips.l.error('Failed to update.');
      var e = 2 * ((UtSystem.getUserTimeMSec() - this.startTimeMSec) / 1e3) * Math.PI;
      this.mainMotionManager.isFinished() && this.startRandomMotion(y, x), this.live2DModel.loadParam();
      this.mainMotionManager.updateParam(this.live2DModel) || null != this.eyeBlink && this.eyeBlink.updateParam(this.live2DModel), this.live2DModel.saveParam(), null == this.expressionManager || null == this.expressions || this.expressionManager.isFinished() || this.expressionManager.updateParam(this.live2DModel), this.live2DModel.addToParamFloat('PARAM_ANGLE_X', 30 * this.dragX, 1), this.live2DModel.addToParamFloat('PARAM_ANGLE_Y', 30 * this.dragY, 1), this.live2DModel.addToParamFloat('PARAM_ANGLE_Z', this.dragX * this.dragY * -30, 1), this.live2DModel.addToParamFloat('PARAM_BODY_ANGLE_X', 10 * this.dragX, 1), this.live2DModel.addToParamFloat('PARAM_EYE_BALL_X', this.dragX, 1), this.live2DModel.addToParamFloat('PARAM_EYE_BALL_Y', this.dragY, 1), this.live2DModel.addToParamFloat('PARAM_ANGLE_X', Number(15 * Math.sin(e / 6.5345)), .5), this.live2DModel.addToParamFloat('PARAM_ANGLE_Y', Number(8 * Math.sin(e / 3.5345)), .5), this.live2DModel.addToParamFloat('PARAM_ANGLE_Z', Number(10 * Math.sin(e / 5.5345)), .5), this.live2DModel.addToParamFloat('PARAM_BODY_ANGLE_X', Number(4 * Math.sin(e / 15.5345)), .5), this.live2DModel.setParamFloat('PARAM_BREATH', Number(.5 + .5 * Math.sin(e / 3.2345)), 1), null != this.physics && this.physics.updateParam(this.live2DModel), null == this.lipSync && this.live2DModel.setParamFloat('PARAM_MOUTH_OPEN_Y', this.lipSyncValue), null != this.pose && this.pose.updateParam(this.live2DModel), this.live2DModel.update();
    }
  }, {
    key: "setRandomExpression",
    value: function setRandomExpression() {
      var t = [];
      for (var _e32 in this.expressions) t.push(_e32);
      var e = parseInt(Math.random() * t.length);
      this.setExpression(t[e]);
    }
  }, {
    key: "startRandomMotion",
    value: function startRandomMotion(t, e) {
      var i = this.modelSetting.getMotionNum(t),
        s = parseInt(Math.random() * i);
      this.startMotion(t, s, e);
    }
  }, {
    key: "startMotion",
    value: function startMotion(e, i, s) {
      var _this17 = this;
      var n = this.modelSetting.getMotionFile(e, i);
      if (null == n || '' == n) return;
      if (s == A) {
        this.mainMotionManager.setReservePriority(s);
      } else if (!this.mainMotionManager.reserveMotion(s)) return void waifu_tips.l.trace('Motion is running.');
      var a;
      null == this.motions[e] ? this.loadMotion(null, this.modelHomeDir + n, function (t) {
        a = t, _this17.setFadeInFadeOut(e, i, s, a);
      }) : (a = this.motions[e], this.setFadeInFadeOut(e, i, s, a));
    }
  }, {
    key: "setFadeInFadeOut",
    value: function setFadeInFadeOut(e, i, s, n) {
      var a = this.modelSetting.getMotionFile(e, i);
      if (n.setFadeIn(this.modelSetting.getMotionFadeIn(e, i)), n.setFadeOut(this.modelSetting.getMotionFadeOut(e, i)), waifu_tips.l.trace('Start motion : ' + a), null == this.modelSetting.getMotionSound(e, i)) {
        this.mainMotionManager.startMotionPrio(n, s);
      } else {
        var _a7 = this.modelSetting.getMotionSound(e, i),
          _r8 = document.createElement('audio');
        _r8.src = this.modelHomeDir + _a7, waifu_tips.l.trace('Start sound : ' + _a7), _r8.play(), this.mainMotionManager.startMotionPrio(n, s);
      }
    }
  }, {
    key: "setExpression",
    value: function setExpression(e) {
      var i;
      var s = this.expressions[e];
      waifu_tips.l.trace('Expression : ' + e), null === (i = this.expressionManager) || void 0 === i || i.startMotion(s, !1);
    }
  }, {
    key: "draw",
    value: function draw(t) {
      w.push(), w.multMatrix(this.modelMatrix.getArray()), this.tmpMatrix = w.getMatrix(), this.live2DModel.setMatrix(this.tmpMatrix), this.live2DModel.draw(), w.pop();
    }
  }, {
    key: "hitTest",
    value: function hitTest(t, e, i) {
      var s = this.modelSetting.getHitAreaNum();
      if (0 == s) {
        var _s8 = this.modelSetting.getHitAreaCustom();
        if (_s8) {
          var _n7 = _s8[t + '_x'],
            _a8 = _s8[t + '_y'];
          if (e > Math.min.apply(Math, _toConsumableArray(_n7)) && e < Math.max.apply(Math, _toConsumableArray(_n7)) && i > Math.min.apply(Math, _toConsumableArray(_a8)) && i < Math.max.apply(Math, _toConsumableArray(_a8))) return !0;
        }
      }
      for (var _n8 = 0; _n8 < s; _n8++) {
        if (t == this.modelSetting.getHitAreaName(_n8)) {
          var _t17 = this.modelSetting.getHitAreaID(_n8);
          return this.hitTestSimple(_t17, e, i);
        }
      }
      return !1;
    }
  }]);
  return U;
}(e);
var X = /*#__PURE__*/function () {
  function X() {
    (0,classCallCheck/* default */.A)(this, X);
    this.cache = {};
  }
  (0,createClass/* default */.A)(X, [{
    key: "loadBytes",
    value: function loadBytes(t, e) {
      var _this18 = this;
      if (t in this.cache) return e(this.cache[t]);
      fetch(t).then(function (t) {
        return t.arrayBuffer();
      }).then(function (i) {
        _this18.cache[t] = i, e(i);
      });
    }
  }, {
    key: "loadLive2DModel",
    value: function loadLive2DModel(t, e) {
      var i = null;
      this.loadBytes(t, function (t) {
        i = Live2DModelWebGL.loadModel(t), e(i);
      });
    }
  }, {
    key: "loadTexture",
    value: function loadTexture(e, i, s, n) {
      var a = new Image();
      a.crossOrigin = 'anonymous', a.src = s, a.onload = function () {
        var s = document.getElementById('live2d').getContext('webgl2', {
          premultipliedAlpha: !0,
          preserveDrawingBuffer: !0
        });
        var r = s.createTexture();
        if (!r) return waifu_tips.l.error('Failed to generate gl texture name.'), -1;
        0 == e.isPremultipliedAlpha() && s.pixelStorei(s.UNPACK_PREMULTIPLY_ALPHA_WEBGL, 1), s.pixelStorei(s.UNPACK_FLIP_Y_WEBGL, 1), s.activeTexture(s.TEXTURE0), s.bindTexture(s.TEXTURE_2D, r), s.texImage2D(s.TEXTURE_2D, 0, s.RGBA, s.RGBA, s.UNSIGNED_BYTE, a), s.texParameteri(s.TEXTURE_2D, s.TEXTURE_MAG_FILTER, s.LINEAR), s.texParameteri(s.TEXTURE_2D, s.TEXTURE_MIN_FILTER, s.LINEAR_MIPMAP_NEAREST), s.generateMipmap(s.TEXTURE_2D), e.setTexture(i, r), r = null, 'function' == typeof n && n();
      }, a.onerror = function () {
        waifu_tips.l.error('Failed to load image : ' + s);
      };
    }
  }, {
    key: "jsonParseFromBytes",
    value: function jsonParseFromBytes(t) {
      var e;
      var i = new Uint8Array(t, 0, 3);
      e = 239 == i[0] && 187 == i[1] && 191 == i[2] ? String.fromCharCode.apply(null, new Uint8Array(t, 3)) : String.fromCharCode.apply(null, new Uint8Array(t));
      return JSON.parse(e);
    }
  }]);
  return X;
}();
var Y = /*#__PURE__*/function () {
  function Y() {
    (0,classCallCheck/* default */.A)(this, Y);
    this.model = null, this.reloading = !1, Live2D.init(), M.setPlatformManager(new X());
  }
  (0,createClass/* default */.A)(Y, [{
    key: "getModel",
    value: function getModel() {
      return this.model;
    }
  }, {
    key: "releaseModel",
    value: function releaseModel(t) {
      this.model && (this.model.release(t), this.model = null);
    }
  }, {
    key: "changeModel",
    value: function () {
      var _changeModel = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee2(t, e) {
        var _this19 = this;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee2$(_context2) {
          while (1) switch (_context2.prev = _context2.next) {
            case 0:
              return _context2.abrupt("return", new Promise(function (i, s) {
                if (_this19.reloading) return;
                _this19.reloading = !0;
                var n = _this19.model,
                  a = new U();
                a.load(t, e, function () {
                  n && n.release(t), _this19.model = a, _this19.reloading = !1, i();
                });
              }));
            case 1:
            case "end":
              return _context2.stop();
          }
        }, _callee2);
      }));
      function changeModel(_x3, _x4) {
        return _changeModel.apply(this, arguments);
      }
      return changeModel;
    }()
  }, {
    key: "changeModelWithJSON",
    value: function () {
      var _changeModelWithJSON = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee3(t, e, i) {
        var s, n;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee3$(_context3) {
          while (1) switch (_context3.prev = _context3.next) {
            case 0:
              if (!this.reloading) {
                _context3.next = 2;
                break;
              }
              return _context3.abrupt("return");
            case 2:
              this.reloading = !0;
              s = this.model, n = new U();
              _context3.next = 6;
              return n.loadModelSetting(e, i);
            case 6:
              s && s.release(t);
              this.model = n;
              this.reloading = !1;
            case 9:
            case "end":
              return _context3.stop();
          }
        }, _callee3, this);
      }));
      function changeModelWithJSON(_x5, _x6, _x7) {
        return _changeModelWithJSON.apply(this, arguments);
      }
      return changeModelWithJSON;
    }()
  }, {
    key: "setDrag",
    value: function setDrag(t, e) {
      this.model && this.model.setDrag(t, e);
    }
  }, {
    key: "maxScaleEvent",
    value: function maxScaleEvent() {
      waifu_tips.l.trace('Max scale event.'), this.model && this.model.startRandomMotion(O, f);
    }
  }, {
    key: "minScaleEvent",
    value: function minScaleEvent() {
      waifu_tips.l.trace('Min scale event.'), this.model && this.model.startRandomMotion(D, f);
    }
  }, {
    key: "tapEvent",
    value: function tapEvent(e, i) {
      return waifu_tips.l.trace('tapEvent view x:' + e + ' y:' + i), !!this.model && (this.model.hitTest(L, e, i) ? (waifu_tips.l.trace('Tap face.'), this.model.setRandomExpression()) : this.model.hitTest(N, e, i) && (waifu_tips.l.trace('Tap body.'), this.model.startRandomMotion(R, f)), !0);
    }
  }]);
  return Y;
}();
function j(t, e, i, s, n, a) {
  var r = t - i,
    o = e - s;
  var h = 0,
    l = 0;
  return h = r >= 0 ? r / (n - i) : r / i, l = o >= 0 ? o / (a - s) : o / s, {
    vx: h,
    vy: -l
  };
}
var G = /*#__PURE__*/function () {
  function G() {
    (0,classCallCheck/* default */.A)(this, G);
    this.live2DMgr = new Y(), this.isDrawStart = !1, this.gl = null, this.canvas = null, this.dragMgr = null, this.viewMatrix = null, this.projMatrix = null, this.deviceToScreen = null, this.oldLen = 0, this._boundMouseEvent = this.mouseEvent.bind(this), this._boundTouchEvent = this.touchEvent.bind(this);
  }
  (0,createClass/* default */.A)(G, [{
    key: "initL2dCanvas",
    value: function initL2dCanvas(t) {
      this.canvas = document.getElementById(t), this.canvas.addEventListener && (this.canvas.addEventListener('mousewheel', this._boundMouseEvent, !1), this.canvas.addEventListener('click', this._boundMouseEvent, !1), document.addEventListener('mousemove', this._boundMouseEvent, !1), document.addEventListener('mouseout', this._boundMouseEvent, !1), this.canvas.addEventListener('contextmenu', this._boundMouseEvent, !1), this.canvas.addEventListener('touchstart', this._boundTouchEvent, !1), this.canvas.addEventListener('touchend', this._boundTouchEvent, !1), this.canvas.addEventListener('touchmove', this._boundTouchEvent, !1));
    }
  }, {
    key: "init",
    value: function () {
      var _init = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee4(e, i, s) {
        var n, a, r, h, l, c, d;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee4$(_context4) {
          while (1) switch (_context4.prev = _context4.next) {
            case 0:
              this.initL2dCanvas(e);
              n = this.canvas.width, a = this.canvas.height;
              this.dragMgr = new m();
              r = a / n, h = p, l = E, c = -r, d = r;
              this.viewMatrix = new g();
              this.viewMatrix.setScreenRect(h, l, c, d);
              this.viewMatrix.setMaxScreenRect(v, P, _, I);
              this.viewMatrix.setMaxScale(S);
              this.viewMatrix.setMinScale(T);
              this.projMatrix = new o();
              this.projMatrix.multScale(1, n / a);
              this.deviceToScreen = new o();
              this.deviceToScreen.multTranslate(-n / 2, -a / 2);
              this.deviceToScreen.multScale(2 / n, -2 / n);
              this.gl = this.canvas.getContext('webgl2', {
                premultipliedAlpha: !0,
                preserveDrawingBuffer: !0
              });
              if (!this.gl) {
                _context4.next = 23;
                break;
              }
              Live2D.setGL(this.gl);
              this.gl.clearColor(0, 0, 0, 0);
              _context4.next = 20;
              return this.changeModelWithJSON(i, s);
            case 20:
              this.startDraw();
              _context4.next = 24;
              break;
            case 23:
              waifu_tips.l.error('Failed to create WebGL context.');
            case 24:
            case "end":
              return _context4.stop();
          }
        }, _callee4, this);
      }));
      function init(_x8, _x9, _x10) {
        return _init.apply(this, arguments);
      }
      return init;
    }()
  }, {
    key: "destroy",
    value: function destroy() {
      this.canvas && (this.canvas.removeEventListener('mousewheel', this._boundMouseEvent, !1), this.canvas.removeEventListener('click', this._boundMouseEvent, !1), document.removeEventListener('mousemove', this._boundMouseEvent, !1), document.removeEventListener('mouseout', this._boundMouseEvent, !1), this.canvas.removeEventListener('contextmenu', this._boundMouseEvent, !1), this.canvas.removeEventListener('touchstart', this._boundTouchEvent, !1), this.canvas.removeEventListener('touchend', this._boundTouchEvent, !1), this.canvas.removeEventListener('touchmove', this._boundTouchEvent, !1)), this._drawFrameId && (window.cancelAnimationFrame(this._drawFrameId), this._drawFrameId = null), this.isDrawStart = !1, this.live2DMgr && 'function' == typeof this.live2DMgr.release && this.live2DMgr.release(), this.gl, this.canvas = null, this.gl = null, this.dragMgr = null, this.viewMatrix = null, this.projMatrix = null, this.deviceToScreen = null;
    }
  }, {
    key: "startDraw",
    value: function startDraw() {
      var _this20 = this;
      if (!this.isDrawStart) {
        this.isDrawStart = !0;
        var _t18 = function _t18() {
          _this20.draw(), _this20._drawFrameId = window.requestAnimationFrame(_t18, _this20.canvas);
        };
        _t18();
      }
    }
  }, {
    key: "draw",
    value: function draw() {
      w.reset(), w.loadIdentity(), this.dragMgr.update(), this.live2DMgr.setDrag(this.dragMgr.getX(), this.dragMgr.getY()), this.gl.clear(this.gl.COLOR_BUFFER_BIT), w.multMatrix(this.projMatrix.getArray()), w.multMatrix(this.viewMatrix.getArray()), w.push();
      var t = this.live2DMgr.getModel();
      null != t && (t.initialized && !t.updating && (t.update(), t.draw(this.gl)), w.pop());
    }
  }, {
    key: "changeModel",
    value: function () {
      var _changeModel2 = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee5(t) {
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee5$(_context5) {
          while (1) switch (_context5.prev = _context5.next) {
            case 0:
              _context5.next = 2;
              return this.live2DMgr.changeModel(this.gl, t);
            case 2:
            case "end":
              return _context5.stop();
          }
        }, _callee5, this);
      }));
      function changeModel(_x11) {
        return _changeModel2.apply(this, arguments);
      }
      return changeModel;
    }()
  }, {
    key: "changeModelWithJSON",
    value: function () {
      var _changeModelWithJSON2 = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee6(t, e) {
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee6$(_context6) {
          while (1) switch (_context6.prev = _context6.next) {
            case 0:
              _context6.next = 2;
              return this.live2DMgr.changeModelWithJSON(this.gl, t, e);
            case 2:
            case "end":
              return _context6.stop();
          }
        }, _callee6, this);
      }));
      function changeModelWithJSON(_x12, _x13) {
        return _changeModelWithJSON2.apply(this, arguments);
      }
      return changeModelWithJSON;
    }()
  }, {
    key: "modelScaling",
    value: function modelScaling(t) {
      var e = this.viewMatrix.isMaxScale(),
        i = this.viewMatrix.isMinScale();
      this.viewMatrix.adjustScale(0, 0, t), e || this.viewMatrix.isMaxScale() && this.live2DMgr.maxScaleEvent(), i || this.viewMatrix.isMinScale() && this.live2DMgr.minScaleEvent();
    }
  }, {
    key: "modelTurnHead",
    value: function modelTurnHead(e) {
      var i;
      var s = this.canvas.getBoundingClientRect(),
        _j = j(e.clientX, e.clientY, s.left + s.width / 2, s.top + s.height / 2, window.innerWidth, window.innerHeight),
        n = _j.vx,
        a = _j.vy;
      waifu_tips.l.trace('onMouseDown device( x:' + e.clientX + ' y:' + e.clientY + ' ) view( x:' + n + ' y:' + a + ')'), this.dragMgr.setPoint(n, a), this.live2DMgr.tapEvent(n, a), (null === (i = this.live2DMgr) || void 0 === i ? void 0 : i.model.hitTest(N, n, a)) && window.dispatchEvent(new Event('live2d:tapbody'));
    }
  }, {
    key: "followPointer",
    value: function followPointer(e) {
      var i;
      var s = this.canvas.getBoundingClientRect(),
        _j2 = j(e.clientX, e.clientY, s.left + s.width / 2, s.top + s.height / 2, window.innerWidth, window.innerHeight),
        n = _j2.vx,
        a = _j2.vy;
      waifu_tips.l.trace('onMouseMove device( x:' + e.clientX + ' y:' + e.clientY + ' ) view( x:' + n + ' y:' + a + ')'), this.dragMgr.setPoint(n, a), (null === (i = this.live2DMgr) || void 0 === i ? void 0 : i.model.hitTest(N, n, a)) && window.dispatchEvent(new Event('live2d:hoverbody'));
    }
  }, {
    key: "lookFront",
    value: function lookFront() {
      this.dragMgr.setPoint(0, 0);
    }
  }, {
    key: "mouseEvent",
    value: function mouseEvent(t) {
      t.preventDefault(), 'mousewheel' == t.type ? t.wheelDelta > 0 ? this.modelScaling(1.1) : this.modelScaling(1) : 'click' == t.type || 'contextmenu' == t.type ? this.modelTurnHead(t) : 'mousemove' == t.type ? this.followPointer(t) : 'mouseout' == t.type && this.lookFront();
    }
  }, {
    key: "touchEvent",
    value: function touchEvent(t) {
      t.preventDefault();
      var e = t.touches[0];
      if ('touchstart' == t.type) {
        1 == t.touches.length && this.modelTurnHead(e);
      } else if ('touchmove' == t.type) {
        if (this.followPointer(e), 2 == t.touches.length) {
          var _e33 = t.touches[0],
            _i14 = t.touches[1],
            _s9 = Math.pow(_e33.pageX - _i14.pageX, 2) + Math.pow(_e33.pageY - _i14.pageY, 2);
          this.oldLen - _s9 < 0 ? this.modelScaling(1.025) : this.modelScaling(.975), this.oldLen = _s9;
        }
      } else {
        'touchend' == t.type && this.lookFront();
      }
    }
  }, {
    key: "transformViewX",
    value: function transformViewX(t) {
      var e = this.deviceToScreen.transformX(t);
      return this.viewMatrix.invertTransformX(e);
    }
  }, {
    key: "transformViewY",
    value: function transformViewY(t) {
      var e = this.deviceToScreen.transformY(t);
      return this.viewMatrix.invertTransformY(e);
    }
  }, {
    key: "transformScreenX",
    value: function transformScreenX(t) {
      return this.deviceToScreen.transformX(t);
    }
  }, {
    key: "transformScreenY",
    value: function transformScreenY(t) {
      return this.deviceToScreen.transformY(t);
    }
  }]);
  return G;
}();


/***/ }),

/***/ 3999:
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {

// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  AppDelegate: function() { return /* binding */ bs; }
});

// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/regeneratorRuntime.js
var regeneratorRuntime = __webpack_require__(2946);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js
var asyncToGenerator = __webpack_require__(1362);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.get-own-property-descriptor.js
var es_object_get_own_property_descriptor = __webpack_require__(3851);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.to-string.js
var es_object_to_string = __webpack_require__(6099);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.reflect.get.js
var es_reflect_get = __webpack_require__(888);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.reflect.to-string-tag.js
var es_reflect_to_string_tag = __webpack_require__(5472);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js
var getPrototypeOf = __webpack_require__(6643);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/superPropBase.js

function _superPropBase(object, property) {
  while (!Object.prototype.hasOwnProperty.call(object, property)) {
    object = (0,getPrototypeOf/* default */.A)(object);
    if (object === null) break;
  }
  return object;
}
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/get.js





function _get() {
  if (typeof Reflect !== "undefined" && Reflect.get) {
    _get = Reflect.get.bind();
  } else {
    _get = function _get(target, property, receiver) {
      var base = _superPropBase(target, property);
      if (!base) return;
      var desc = Object.getOwnPropertyDescriptor(base, property);
      if (desc.get) {
        return desc.get.call(arguments.length < 3 ? target : receiver);
      }
      return desc.value;
    };
  }
  return _get.apply(this, arguments);
}
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/callSuper.js + 3 modules
var callSuper = __webpack_require__(2934);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/inherits.js + 1 modules
var inherits = __webpack_require__(6229);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js
var classCallCheck = __webpack_require__(1512);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/createClass.js + 2 modules
var createClass = __webpack_require__(5629);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.error.cause.js
var es_error_cause = __webpack_require__(6280);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.at.js
var es_array_at = __webpack_require__(8107);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.concat.js
var es_array_concat = __webpack_require__(8706);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.index-of.js
var es_array_index_of = __webpack_require__(5276);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js
var es_array_push = __webpack_require__(4114);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.slice.js
var es_array_slice = __webpack_require__(4782);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.splice.js
var es_array_splice = __webpack_require__(4554);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array-buffer.constructor.js
var es_array_buffer_constructor = __webpack_require__(4743);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array-buffer.slice.js
var es_array_buffer_slice = __webpack_require__(1745);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.json.stringify.js
var es_json_stringify = __webpack_require__(3110);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.math.sign.js
var es_math_sign = __webpack_require__(5914);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.number.constructor.js
var es_number_constructor = __webpack_require__(2892);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.freeze.js
var es_object_freeze = __webpack_require__(2811);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.keys.js
var es_object_keys = __webpack_require__(9432);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.exec.js
var es_regexp_exec = __webpack_require__(7495);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.to-string.js
var es_regexp_to_string = __webpack_require__(8781);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.at-alternative.js
var es_string_at_alternative = __webpack_require__(7357);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.replace.js
var es_string_replace = __webpack_require__(5440);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.float32-array.js
var es_typed_array_float32_array = __webpack_require__(4594);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.uint8-array.js
var es_typed_array_uint8_array = __webpack_require__(1489);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.uint16-array.js
var es_typed_array_uint16_array = __webpack_require__(3690);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.at.js
var es_typed_array_at = __webpack_require__(8140);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.copy-within.js
var es_typed_array_copy_within = __webpack_require__(1630);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.every.js
var es_typed_array_every = __webpack_require__(2170);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.fill.js
var es_typed_array_fill = __webpack_require__(5044);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.filter.js
var es_typed_array_filter = __webpack_require__(1920);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.find.js
var es_typed_array_find = __webpack_require__(1694);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.find-index.js
var es_typed_array_find_index = __webpack_require__(9955);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.find-last.js
var es_typed_array_find_last = __webpack_require__(1903);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.find-last-index.js
var es_typed_array_find_last_index = __webpack_require__(1134);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.for-each.js
var es_typed_array_for_each = __webpack_require__(3206);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.from.js
var es_typed_array_from = __webpack_require__(8345);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.includes.js
var es_typed_array_includes = __webpack_require__(4496);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.index-of.js
var es_typed_array_index_of = __webpack_require__(6651);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.iterator.js
var es_typed_array_iterator = __webpack_require__(2887);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.join.js
var es_typed_array_join = __webpack_require__(9369);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.last-index-of.js
var es_typed_array_last_index_of = __webpack_require__(6812);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.map.js
var es_typed_array_map = __webpack_require__(8995);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.reduce.js
var es_typed_array_reduce = __webpack_require__(1575);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.reduce-right.js
var es_typed_array_reduce_right = __webpack_require__(6072);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.reverse.js
var es_typed_array_reverse = __webpack_require__(8747);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.set.js
var es_typed_array_set = __webpack_require__(8845);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.slice.js
var es_typed_array_slice = __webpack_require__(9423);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.some.js
var es_typed_array_some = __webpack_require__(7301);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.sort.js
var es_typed_array_sort = __webpack_require__(373);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-locale-string.js
var es_typed_array_to_locale_string = __webpack_require__(1405);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-reversed.js
var es_typed_array_to_reversed = __webpack_require__(7467);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-sorted.js
var es_typed_array_to_sorted = __webpack_require__(4732);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.to-string.js
var es_typed_array_to_string = __webpack_require__(3684);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.typed-array.with.js
var es_typed_array_with = __webpack_require__(9577);
// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.array-buffer.detached.js
var esnext_array_buffer_detached = __webpack_require__(3899);
// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.array-buffer.transfer.js
var esnext_array_buffer_transfer = __webpack_require__(7913);
// EXTERNAL MODULE: ./node_modules/core-js/modules/esnext.array-buffer.transfer-to-fixed-length.js
var esnext_array_buffer_transfer_to_fixed_length = __webpack_require__(7801);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.for-each.js
var web_dom_collections_for_each = __webpack_require__(3500);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.iterator.js
var web_dom_collections_iterator = __webpack_require__(2953);
// EXTERNAL MODULE: ./src/components/waifu-tips.js + 1 modules
var waifu_tips = __webpack_require__(5673);
;// CONCATENATED MODULE: ./src/components/chunk/index2.js
































































/*!
 * Live2D Widget
 * https://github.com/stevenjoezhang/live2d-widget
 */

var e = /*#__PURE__*/function () {
  function e() {
    var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
    (0,classCallCheck/* default */.A)(this, e);
    t < 1 ? (this._ptr = [], this._capacity = 0, this._size = 0) : (this._ptr = new Array(t), this._capacity = t, this._size = 0);
  }
  (0,createClass/* default */.A)(e, [{
    key: "at",
    value: function at(t) {
      return this._ptr[t];
    }
  }, {
    key: "set",
    value: function set(t, _e2) {
      this._ptr[t] = _e2;
    }
  }, {
    key: "get",
    value: function get() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      var _e3 = new Array();
      for (var _i2 = t; _i2 < this._size; _i2++) _e3.push(this._ptr[_i2]);
      return _e3;
    }
  }, {
    key: "pushBack",
    value: function pushBack(t) {
      this._size >= this._capacity && this.prepareCapacity(0 == this._capacity ? e.DefaultSize : 2 * this._capacity), this._ptr[this._size++] = t;
    }
  }, {
    key: "clear",
    value: function clear() {
      this._ptr.length = 0, this._size = 0;
    }
  }, {
    key: "getSize",
    value: function getSize() {
      return this._size;
    }
  }, {
    key: "assign",
    value: function assign(t, _e4) {
      this._size < t && this.prepareCapacity(t);
      for (var _i3 = 0; _i3 < t; _i3++) this._ptr[_i3] = _e4;
      this._size = t;
    }
  }, {
    key: "resize",
    value: function resize(t) {
      var _e5 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      this.updateSize(t, _e5, !0);
    }
  }, {
    key: "updateSize",
    value: function updateSize(t) {
      var _e6 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : !0;
      if (this._size < t) {
        if (this.prepareCapacity(t), i) for (var _i4 = this._size; _i4 < t; _i4++) {
          this._ptr[_i4] = 'function' == typeof _e6 ? JSON.parse(JSON.stringify(new _e6())) : _e6;
        } else for (var _i5 = this._size; _i5 < t; _i5++) this._ptr[_i5] = _e6;
      } else {
        var _e7 = this._size - t;
        this._ptr.splice(this._size - _e7, _e7);
      }
      this._size = t;
    }
  }, {
    key: "insert",
    value: function insert(t, _e8, i) {
      var s = t._index;
      var r = _e8._index,
        a = i._index,
        n = a - r;
      this.prepareCapacity(this._size + n);
      var o = this._size - s;
      if (o > 0) for (var _t2 = 0; _t2 < o; _t2++) this._ptr.splice(s + _t2, 0, null);
      for (var _t3 = r; _t3 < a; _t3++, s++) this._ptr[s] = _e8._vector._ptr[_t3];
      this._size = this._size + n;
    }
  }, {
    key: "remove",
    value: function remove(t) {
      return !(t < 0 || this._size <= t) && (this._ptr.splice(t, 1), --this._size, !0);
    }
  }, {
    key: "erase",
    value: function erase(t) {
      var _e9 = t._index;
      if (_e9 < 0 || this._size <= _e9) return t;
      this._ptr.splice(_e9, 1), --this._size;
      return new i(this, _e9);
    }
  }, {
    key: "prepareCapacity",
    value: function prepareCapacity(t) {
      t > this._capacity && (0 == this._capacity ? (this._ptr = new Array(t), this._capacity = t) : (this._ptr.length = t, this._capacity = t));
    }
  }, {
    key: "begin",
    value: function begin() {
      return 0 == this._size ? this.end() : new i(this, 0);
    }
  }, {
    key: "end",
    value: function end() {
      return new i(this, this._size);
    }
  }, {
    key: "getOffset",
    value: function getOffset(t) {
      var i = new e();
      return i._ptr = this.get(t), i._size = this.get(t).length, i._capacity = this.get(t).length, i;
    }
  }]);
  return e;
}();
e.DefaultSize = 10;
var i = /*#__PURE__*/function () {
  function t(_t4, e) {
    (0,classCallCheck/* default */.A)(this, t);
    this._vector = null != _t4 ? _t4 : null, this._index = null != e ? e : 0;
  }
  (0,createClass/* default */.A)(t, [{
    key: "set",
    value: function set(_t5) {
      return this._index = _t5._index, this._vector = _t5._vector, this;
    }
  }, {
    key: "preIncrement",
    value: function preIncrement() {
      return ++this._index, this;
    }
  }, {
    key: "preDecrement",
    value: function preDecrement() {
      return --this._index, this;
    }
  }, {
    key: "increment",
    value: function increment() {
      return new t(this._vector, this._index++);
    }
  }, {
    key: "decrement",
    value: function decrement() {
      return new t(this._vector, this._index--);
    }
  }, {
    key: "ptr",
    value: function ptr() {
      return this._vector._ptr[this._index];
    }
  }, {
    key: "substitution",
    value: function substitution(_t6) {
      return this._index = _t6._index, this._vector = _t6._vector, this;
    }
  }, {
    key: "notEqual",
    value: function notEqual(_t7) {
      return this._index != _t7._index || this._vector != _t7._vector;
    }
  }]);
  return t;
}();
var s, r, a, n, o, l, h, u;
!function (t) {
  t.csmVector = e, t.iterator = i;
}(s || (s = {}));
var g = /*#__PURE__*/function () {
  function g(t) {
    (0,classCallCheck/* default */.A)(this, g);
    this.s = t;
  }
  (0,createClass/* default */.A)(g, [{
    key: "append",
    value: function append(t, e) {
      return this.s += void 0 !== e ? t.substr(0, e) : t, this;
    }
  }, {
    key: "expansion",
    value: function expansion(t, e) {
      for (var _i6 = 0; _i6 < t; _i6++) this.append(e);
      return this;
    }
  }, {
    key: "getBytes",
    value: function getBytes() {
      return encodeURIComponent(this.s).replace(/%../g, 'x').length;
    }
  }, {
    key: "getLength",
    value: function getLength() {
      return this.s.length;
    }
  }, {
    key: "isLess",
    value: function isLess(t) {
      return this.s < t.s;
    }
  }, {
    key: "isGreat",
    value: function isGreat(t) {
      return this.s > t.s;
    }
  }, {
    key: "isEqual",
    value: function isEqual(t) {
      return this.s == t;
    }
  }, {
    key: "isEmpty",
    value: function isEmpty() {
      return 0 == this.s.length;
    }
  }]);
  return g;
}();
(r || (r = {})).csmString = g;
var d = /*#__PURE__*/function () {
  function d(t) {
    (0,classCallCheck/* default */.A)(this, d);
    this._id = 'string' != typeof t ? t : new g(t);
  }
  (0,createClass/* default */.A)(d, [{
    key: "getString",
    value: function getString() {
      return this._id;
    }
  }, {
    key: "isEqual",
    value: function isEqual(t) {
      return 'string' == typeof t ? this._id.isEqual(t) : t instanceof g ? this._id.isEqual(t.s) : t instanceof d && this._id.isEqual(t._id.s);
    }
  }, {
    key: "isNotEqual",
    value: function isNotEqual(t) {
      return 'string' == typeof t ? !this._id.isEqual(t) : t instanceof g ? !this._id.isEqual(t.s) : t instanceof d && !this._id.isEqual(t._id.s);
    }
  }], [{
    key: "createIdInternal",
    value: function createIdInternal(t) {
      return new d(t);
    }
  }]);
  return d;
}();
(a || (a = {})).CubismId = d;
var _ = /*#__PURE__*/function () {
  function _() {
    (0,classCallCheck/* default */.A)(this, _);
    this._ids = new e();
  }
  (0,createClass/* default */.A)(_, [{
    key: "release",
    value: function release() {
      for (var _t8 = 0; _t8 < this._ids.getSize(); ++_t8) this._ids.set(_t8, void 0);
      this._ids = null;
    }
  }, {
    key: "registerIds",
    value: function registerIds(t) {
      for (var _e10 = 0; _e10 < t.length; _e10++) this.registerId(t[_e10]);
    }
  }, {
    key: "registerId",
    value: function registerId(t) {
      var e = null;
      return 'string' != typeof t ? this.registerId(t.s) : (null != (e = this.findId(t)) || (e = d.createIdInternal(t), this._ids.pushBack(e)), e);
    }
  }, {
    key: "getId",
    value: function getId(t) {
      return this.registerId(t);
    }
  }, {
    key: "isExist",
    value: function isExist(t) {
      return 'string' == typeof t ? null != this.findId(t) : this.isExist(t.s);
    }
  }, {
    key: "findId",
    value: function findId(t) {
      for (var _e11 = 0; _e11 < this._ids.getSize(); ++_e11) if (this._ids.at(_e11).getString().isEqual(t)) return this._ids.at(_e11);
      return null;
    }
  }]);
  return _;
}();
(n || (n = {})).CubismIdManager = _;
var c = /*#__PURE__*/function () {
  function c() {
    (0,classCallCheck/* default */.A)(this, c);
    this._tr = new Float32Array(16), this.loadIdentity();
  }
  (0,createClass/* default */.A)(c, [{
    key: "loadIdentity",
    value: function loadIdentity() {
      var t = new Float32Array([1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]);
      this.setMatrix(t);
    }
  }, {
    key: "setMatrix",
    value: function setMatrix(t) {
      for (var _e12 = 0; _e12 < 16; ++_e12) this._tr[_e12] = t[_e12];
    }
  }, {
    key: "getArray",
    value: function getArray() {
      return this._tr;
    }
  }, {
    key: "getScaleX",
    value: function getScaleX() {
      return this._tr[0];
    }
  }, {
    key: "getScaleY",
    value: function getScaleY() {
      return this._tr[5];
    }
  }, {
    key: "getTranslateX",
    value: function getTranslateX() {
      return this._tr[12];
    }
  }, {
    key: "getTranslateY",
    value: function getTranslateY() {
      return this._tr[13];
    }
  }, {
    key: "transformX",
    value: function transformX(t) {
      return this._tr[0] * t + this._tr[12];
    }
  }, {
    key: "transformY",
    value: function transformY(t) {
      return this._tr[5] * t + this._tr[13];
    }
  }, {
    key: "invertTransformX",
    value: function invertTransformX(t) {
      return (t - this._tr[12]) / this._tr[0];
    }
  }, {
    key: "invertTransformY",
    value: function invertTransformY(t) {
      return (t - this._tr[13]) / this._tr[5];
    }
  }, {
    key: "translateRelative",
    value: function translateRelative(t, e) {
      var i = new Float32Array([1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, t, e, 0, 1]);
      c.multiply(i, this._tr, this._tr);
    }
  }, {
    key: "translate",
    value: function translate(t, e) {
      this._tr[12] = t, this._tr[13] = e;
    }
  }, {
    key: "translateX",
    value: function translateX(t) {
      this._tr[12] = t;
    }
  }, {
    key: "translateY",
    value: function translateY(t) {
      this._tr[13] = t;
    }
  }, {
    key: "scaleRelative",
    value: function scaleRelative(t, e) {
      var i = new Float32Array([t, 0, 0, 0, 0, e, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]);
      c.multiply(i, this._tr, this._tr);
    }
  }, {
    key: "scale",
    value: function scale(t, e) {
      this._tr[0] = t, this._tr[5] = e;
    }
  }, {
    key: "multiplyByMatrix",
    value: function multiplyByMatrix(t) {
      c.multiply(t.getArray(), this._tr, this._tr);
    }
  }, {
    key: "clone",
    value: function clone() {
      var t = new c();
      for (var _e13 = 0; _e13 < this._tr.length; _e13++) t._tr[_e13] = this._tr[_e13];
      return t;
    }
  }], [{
    key: "multiply",
    value: function multiply(t, e, i) {
      var s = new Float32Array([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
      for (var _i7 = 0; _i7 < 4; ++_i7) for (var _r = 0; _r < 4; ++_r) for (var _a = 0; _a < 4; ++_a) s[_r + 4 * _i7] += t[_a + 4 * _i7] * e[_r + 4 * _a];
      for (var _t9 = 0; _t9 < 16; ++_t9) i[_t9] = s[_t9];
    }
  }]);
  return c;
}();
(o || (o = {})).CubismMatrix44 = c;
var m = /*#__PURE__*/function () {
  function m(t, e, i, s) {
    (0,classCallCheck/* default */.A)(this, m);
    this.x = t, this.y = e, this.width = i, this.height = s;
  }
  (0,createClass/* default */.A)(m, [{
    key: "getCenterX",
    value: function getCenterX() {
      return this.x + .5 * this.width;
    }
  }, {
    key: "getCenterY",
    value: function getCenterY() {
      return this.y + .5 * this.height;
    }
  }, {
    key: "getRight",
    value: function getRight() {
      return this.x + this.width;
    }
  }, {
    key: "getBottom",
    value: function getBottom() {
      return this.y + this.height;
    }
  }, {
    key: "setRect",
    value: function setRect(t) {
      this.x = t.x, this.y = t.y, this.width = t.width, this.height = t.height;
    }
  }, {
    key: "expand",
    value: function expand(t, e) {
      this.x -= t, this.y -= e, this.width += 2 * t, this.height += 2 * e;
    }
  }]);
  return m;
}();
(l || (l = {})).csmRect = m;
var p = /*#__PURE__*/function () {
  function p() {
    (0,classCallCheck/* default */.A)(this, p);
    this._isCulling = !1, this._isPremultipliedAlpha = !1, this._anisotropy = 0, this._model = null, this._modelColor = new f(), this._useHighPrecisionMask = !1, this._mvpMatrix4x4 = new c(), this._mvpMatrix4x4.loadIdentity();
  }
  (0,createClass/* default */.A)(p, [{
    key: "initialize",
    value: function initialize(t) {
      this._model = t;
    }
  }, {
    key: "drawModel",
    value: function drawModel() {
      null != this.getModel() && (this.saveProfile(), this.doDrawModel(), this.restoreProfile());
    }
  }, {
    key: "setMvpMatrix",
    value: function setMvpMatrix(t) {
      this._mvpMatrix4x4.setMatrix(t.getArray());
    }
  }, {
    key: "getMvpMatrix",
    value: function getMvpMatrix() {
      return this._mvpMatrix4x4;
    }
  }, {
    key: "setModelColor",
    value: function setModelColor(t, e, i, s) {
      t < 0 ? t = 0 : t > 1 && (t = 1), e < 0 ? e = 0 : e > 1 && (e = 1), i < 0 ? i = 0 : i > 1 && (i = 1), s < 0 ? s = 0 : s > 1 && (s = 1), this._modelColor.r = t, this._modelColor.g = e, this._modelColor.b = i, this._modelColor.a = s;
    }
  }, {
    key: "getModelColor",
    value: function getModelColor() {
      return JSON.parse(JSON.stringify(this._modelColor));
    }
  }, {
    key: "getModelColorWithOpacity",
    value: function getModelColorWithOpacity(t) {
      var e = this.getModelColor();
      return e.a *= t, this.isPremultipliedAlpha() && (e.r *= e.a, e.g *= e.a, e.b *= e.a), e;
    }
  }, {
    key: "setIsPremultipliedAlpha",
    value: function setIsPremultipliedAlpha(t) {
      this._isPremultipliedAlpha = t;
    }
  }, {
    key: "isPremultipliedAlpha",
    value: function isPremultipliedAlpha() {
      return this._isPremultipliedAlpha;
    }
  }, {
    key: "setIsCulling",
    value: function setIsCulling(t) {
      this._isCulling = t;
    }
  }, {
    key: "isCulling",
    value: function isCulling() {
      return this._isCulling;
    }
  }, {
    key: "setAnisotropy",
    value: function setAnisotropy(t) {
      this._anisotropy = t;
    }
  }, {
    key: "getAnisotropy",
    value: function getAnisotropy() {
      return this._anisotropy;
    }
  }, {
    key: "getModel",
    value: function getModel() {
      return this._model;
    }
  }, {
    key: "useHighPrecisionMask",
    value: function useHighPrecisionMask(t) {
      this._useHighPrecisionMask = t;
    }
  }, {
    key: "isUsingHighPrecisionMask",
    value: function isUsingHighPrecisionMask() {
      return this._useHighPrecisionMask;
    }
  }], [{
    key: "create",
    value: function create() {
      return null;
    }
  }, {
    key: "delete",
    value: function _delete(t) {}
  }]);
  return p;
}();
!function (t) {
  t[t.CubismBlendMode_Normal = 0] = 'CubismBlendMode_Normal', t[t.CubismBlendMode_Additive = 1] = 'CubismBlendMode_Additive', t[t.CubismBlendMode_Multiplicative = 2] = 'CubismBlendMode_Multiplicative';
}(h || (h = {}));
var f = /*#__PURE__*/(0,createClass/* default */.A)(function f() {
  var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1;
  var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
  var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
  var s = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 1;
  (0,classCallCheck/* default */.A)(this, f);
  this.r = t, this.g = e, this.b = i, this.a = s;
});
var y = /*#__PURE__*/function () {
  function y(t, e) {
    (0,classCallCheck/* default */.A)(this, y);
    this._clippingIdList = t, this._clippingIdCount = e, this._allClippedDrawRect = new m(), this._layoutBounds = new m(), this._clippedDrawableIndexList = [], this._matrixForMask = new c(), this._matrixForDraw = new c(), this._bufferIndex = 0;
  }
  (0,createClass/* default */.A)(y, [{
    key: "release",
    value: function release() {
      null != this._layoutBounds && (this._layoutBounds = null), null != this._allClippedDrawRect && (this._allClippedDrawRect = null), null != this._clippedDrawableIndexList && (this._clippedDrawableIndexList = null);
    }
  }, {
    key: "addClippedDrawable",
    value: function addClippedDrawable(t) {
      this._clippedDrawableIndexList.push(t);
    }
  }]);
  return y;
}();
!function (t) {
  t.CubismBlendMode = h, t.CubismRenderer = p, t.CubismTextureColor = f;
}(u || (u = {}));
var S = function S(t, e, i) {
    (function (t, e, i) {
      P.print(t, '[CSM]' + e, i);
    })(t, e + '\n', i);
  },
  C = function C(t) {
    console.assert(t);
  };
var x, M, v, b;
x = function x(t) {
  for (var _len = arguments.length, e = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
    e[_key - 1] = arguments[_key];
  }
  S(K.LogLevel_Debug, '[D]' + t, e);
}, M = function M(t) {
  for (var _len2 = arguments.length, e = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
    e[_key2 - 1] = arguments[_key2];
  }
  S(K.LogLevel_Info, '[I]' + t, e);
}, v = function v(t) {
  for (var _len3 = arguments.length, e = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
    e[_key3 - 1] = arguments[_key3];
  }
  S(K.LogLevel_Warning, '[W]' + t, e);
}, b = function b(t) {
  for (var _len4 = arguments.length, e = new Array(_len4 > 1 ? _len4 - 1 : 0), _key4 = 1; _key4 < _len4; _key4++) {
    e[_key4 - 1] = arguments[_key4];
  }
  S(K.LogLevel_Error, '[E]' + t, e);
};
var P = /*#__PURE__*/function () {
  function P() {
    (0,classCallCheck/* default */.A)(this, P);
  }
  (0,createClass/* default */.A)(P, null, [{
    key: "print",
    value: function print(t, e, i) {
      if (t < $.getLoggingLevel()) return;
      var s = $.coreLogFunction;
      if (!s) return;
      s(e.replace(/\{(\d+)\}/g, function (t, e) {
        return i[e];
      }));
    }
  }, {
    key: "dumpBytes",
    value: function dumpBytes(t, e, i) {
      for (var _s2 = 0; _s2 < i; _s2++) _s2 % 16 == 0 && _s2 > 0 ? this.print(t, '\n') : _s2 % 8 == 0 && _s2 > 0 && this.print(t, '  '), this.print(t, '{0} ', [255 & e[_s2]]);
      this.print(t, '\n');
    }
  }]);
  return P;
}();
var B, w;
(B || (B = {})).CubismDebug = P;
var F = /*#__PURE__*/(0,createClass/* default */.A)(function F(t, e) {
  (0,classCallCheck/* default */.A)(this, F);
  this.first = null == t ? null : t, this.second = null == e ? null : e;
});
var I = /*#__PURE__*/function () {
  function I(t) {
    (0,classCallCheck/* default */.A)(this, I);
    null != t ? t < 1 ? (this._keyValues = [], this._dummyValue = null, this._size = 0) : (this._keyValues = new Array(t), this._size = t) : (this._keyValues = [], this._dummyValue = null, this._size = 0);
  }
  (0,createClass/* default */.A)(I, [{
    key: "release",
    value: function release() {
      this.clear();
    }
  }, {
    key: "appendKey",
    value: function appendKey(t) {
      var e = -1;
      for (var _i8 = 0; _i8 < this._size; _i8++) {
        if (this._keyValues[_i8].first == t) {
          e = _i8;
          break;
        }
      }
      -1 == e ? (this.prepareCapacity(this._size + 1, !1), this._keyValues[this._size] = new F(t), this._size += 1) : v('The key `{0}` is already append.', t);
    }
  }, {
    key: "getValue",
    value: function getValue(t) {
      var e = -1;
      for (var _i9 = 0; _i9 < this._size; _i9++) {
        if (this._keyValues[_i9].first == t) {
          e = _i9;
          break;
        }
      }
      return e >= 0 ? this._keyValues[e].second : (this.appendKey(t), this._keyValues[this._size - 1].second);
    }
  }, {
    key: "setValue",
    value: function setValue(t, e) {
      var i = -1;
      for (var _e14 = 0; _e14 < this._size; _e14++) {
        if (this._keyValues[_e14].first == t) {
          i = _e14;
          break;
        }
      }
      i >= 0 ? this._keyValues[i].second = e : (this.appendKey(t), this._keyValues[this._size - 1].second = e);
    }
  }, {
    key: "isExist",
    value: function isExist(t) {
      for (var _e15 = 0; _e15 < this._size; _e15++) if (this._keyValues[_e15].first == t) return !0;
      return !1;
    }
  }, {
    key: "clear",
    value: function clear() {
      this._keyValues = void 0, this._keyValues = null, this._keyValues = [], this._size = 0;
    }
  }, {
    key: "getSize",
    value: function getSize() {
      return this._size;
    }
  }, {
    key: "prepareCapacity",
    value: function prepareCapacity(t, e) {
      t > this._keyValues.length && (0 == this._keyValues.length ? (!e && t < I.DefaultSize && (t = I.DefaultSize), this._keyValues.length = t) : (!e && t < 2 * this._keyValues.length && (t = 2 * this._keyValues.length), this._keyValues.length = t));
    }
  }, {
    key: "begin",
    value: function begin() {
      return new V(this, 0);
    }
  }, {
    key: "end",
    value: function end() {
      return new V(this, this._size);
    }
  }, {
    key: "erase",
    value: function erase(t) {
      var e = t._index;
      if (e < 0 || this._size <= e) return t;
      this._keyValues.splice(e, 1), --this._size;
      return new V(this, e);
    }
  }, {
    key: "dumpAsInt",
    value: function dumpAsInt() {
      for (var _t10 = 0; _t10 < this._size; _t10++) x('{0} ,', this._keyValues[_t10]), x('\n');
    }
  }]);
  return I;
}();
I.DefaultSize = 10;
var V = /*#__PURE__*/function () {
  function V(t, e) {
    (0,classCallCheck/* default */.A)(this, V);
    this._map = null != t ? t : new I(), this._index = null != e ? e : 0;
  }
  (0,createClass/* default */.A)(V, [{
    key: "set",
    value: function set(t) {
      return this._index = t._index, this._map = t._map, this;
    }
  }, {
    key: "preIncrement",
    value: function preIncrement() {
      return ++this._index, this;
    }
  }, {
    key: "preDecrement",
    value: function preDecrement() {
      return --this._index, this;
    }
  }, {
    key: "increment",
    value: function increment() {
      return new V(this._map, this._index++);
    }
  }, {
    key: "decrement",
    value: function decrement() {
      var t = new V(this._map, this._index);
      return this._map = t._map, this._index = t._index, this;
    }
  }, {
    key: "ptr",
    value: function ptr() {
      return this._map._keyValues[this._index];
    }
  }, {
    key: "notEqual",
    value: function notEqual(t) {
      return this._index != t._index || this._map != t._map;
    }
  }]);
  return V;
}();
!function (t) {
  t.csmMap = I, t.csmPair = F, t.iterator = V;
}(w || (w = {}));
var E = /*#__PURE__*/function () {
  function E() {
    (0,classCallCheck/* default */.A)(this, E);
  }
  (0,createClass/* default */.A)(E, null, [{
    key: "parseJsonObject",
    value: function parseJsonObject(t, e) {
      return Object.keys(t).forEach(function (i) {
        if ('boolean' == typeof t[i]) {
          var _s3 = Boolean(t[i]);
          e.put(i, new A(_s3));
        } else if ('string' == typeof t[i]) {
          var _s4 = String(t[i]);
          e.put(i, new O(_s4));
        } else if ('number' == typeof t[i]) {
          var _s5 = Number(t[i]);
          e.put(i, new D(_s5));
        } else {
          t[i] instanceof Array ? e.put(i, E.parseJsonArray(t[i])) : t[i] instanceof Object ? e.put(i, E.parseJsonObject(t[i], new U())) : null == t[i] ? e.put(i, new N()) : e.put(i, t[i]);
        }
      }), e;
    }
  }, {
    key: "parseJsonArray",
    value: function parseJsonArray(t) {
      var _this = this;
      var e = new z();
      return Object.keys(t).forEach(function (i) {
        if ('number' == typeof Number(i)) {
          if ('boolean' == typeof t[i]) {
            var _s6 = Boolean(t[i]);
            e.add(new A(_s6));
          } else if ('string' == typeof t[i]) {
            var _s7 = String(t[i]);
            e.add(new O(_s7));
          } else if ('number' == typeof t[i]) {
            var _s8 = Number(t[i]);
            e.add(new D(_s8));
          } else {
            t[i] instanceof Array ? e.add(_this.parseJsonArray(t[i])) : t[i] instanceof Object ? e.add(_this.parseJsonObject(t[i], new U())) : null == t[i] ? e.add(new N()) : e.add(t[i]);
          }
        } else if (t[i] instanceof Array) {
          e.add(_this.parseJsonArray(t[i]));
        } else if (t[i] instanceof Object) {
          e.add(_this.parseJsonObject(t[i], new U()));
        } else if (null == t[i]) {
          e.add(new N());
        } else {
          var _s9 = Array(t[i]);
          for (var _t11 = 0; _t11 < _s9.length; _t11++) e.add(_s9[_t11]);
        }
      }), e;
    }
  }]);
  return E;
}();
var R = 'Error: type mismatch';
var T = /*#__PURE__*/function () {
  function t() {
    (0,classCallCheck/* default */.A)(this, t);
  }
  (0,createClass/* default */.A)(t, [{
    key: "getRawString",
    value: function getRawString(_t12, e) {
      return this.getString(_t12, e);
    }
  }, {
    key: "toInt",
    value: function toInt() {
      var _t13 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      return _t13;
    }
  }, {
    key: "toFloat",
    value: function toFloat() {
      var _t14 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      return _t14;
    }
  }, {
    key: "toBoolean",
    value: function toBoolean() {
      var _t15 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : !1;
      return _t15;
    }
  }, {
    key: "getSize",
    value: function getSize() {
      return 0;
    }
  }, {
    key: "getArray",
    value: function getArray() {
      var _t16 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
      return _t16;
    }
  }, {
    key: "getVector",
    value: function getVector() {
      var _t17 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : new e();
      return _t17;
    }
  }, {
    key: "getMap",
    value: function getMap(_t18) {
      return _t18;
    }
  }, {
    key: "getValueByIndex",
    value: function getValueByIndex(e) {
      return t.errorValue.setErrorNotForClientCall(R);
    }
  }, {
    key: "getValueByString",
    value: function getValueByString(e) {
      return t.nullValue.setErrorNotForClientCall(R);
    }
  }, {
    key: "getKeys",
    value: function getKeys() {
      return t.dummyKeys;
    }
  }, {
    key: "isError",
    value: function isError() {
      return !1;
    }
  }, {
    key: "isNull",
    value: function isNull() {
      return !1;
    }
  }, {
    key: "isBool",
    value: function isBool() {
      return !1;
    }
  }, {
    key: "isFloat",
    value: function isFloat() {
      return !1;
    }
  }, {
    key: "isString",
    value: function isString() {
      return !1;
    }
  }, {
    key: "isArray",
    value: function isArray() {
      return !1;
    }
  }, {
    key: "isMap",
    value: function isMap() {
      return !1;
    }
  }, {
    key: "equals",
    value: function equals(_t19) {
      return !1;
    }
  }, {
    key: "isStatic",
    value: function isStatic() {
      return !1;
    }
  }, {
    key: "setErrorNotForClientCall",
    value: function setErrorNotForClientCall(_t20) {
      return k.errorValue;
    }
  }], [{
    key: "staticInitializeNotForClientCall",
    value: function staticInitializeNotForClientCall() {
      A.trueValue = new A(!0), A.falseValue = new A(!1), t.errorValue = new k('ERROR', !0), t.nullValue = new N(), t.dummyKeys = new e();
    }
  }, {
    key: "staticReleaseNotForClientCall",
    value: function staticReleaseNotForClientCall() {
      A.trueValue = null, A.falseValue = null, t.errorValue = null, t.nullValue = null, t.dummyKeys = null;
    }
  }]);
  return t;
}();
var L = /*#__PURE__*/function () {
  function L(t, e) {
    (0,classCallCheck/* default */.A)(this, L);
    this._parseCallback = E.parseJsonObject, this._error = null, this._lineCount = 0, this._root = null, null != t && this.parseBytes(t, e, this._parseCallback);
  }
  (0,createClass/* default */.A)(L, [{
    key: "getRoot",
    value: function getRoot() {
      return this._root;
    }
  }, {
    key: "parseBytes",
    value: function parseBytes(t, e, i) {
      var s = new Array(1),
        r = L.arrayBufferToString(t);
      if (this._root = null == i ? this.parseValue(r, e, 0, s) : i(JSON.parse(r), new U()), this._error) {
        var _t21 = '\0';
        return _t21 = 'Json parse error : @line ' + (this._lineCount + 1) + '\n', this._root = new O(_t21), M('{0}', this._root.getRawString()), !1;
      }
      return null != this._root || (this._root = new k(new g(this._error), !1), !1);
    }
  }, {
    key: "getParseError",
    value: function getParseError() {
      return this._error;
    }
  }, {
    key: "checkEndOfFile",
    value: function checkEndOfFile() {
      return this._root.getArray()[1].equals('EOF');
    }
  }, {
    key: "parseValue",
    value: function parseValue(t, e, i, s) {
      if (this._error) return null;
      var r,
        a = null,
        n = i;
      for (; n < e; n++) {
        switch (t[n]) {
          case '-':
          case '.':
          case '0':
          case '1':
          case '2':
          case '3':
          case '4':
          case '5':
          case '6':
          case '7':
          case '8':
          case '9':
            {
              var _e16 = new Array(1);
              return r = X(t.slice(n), _e16), s[0] = t.indexOf(_e16[0]), new D(r);
            }
          case '"':
            return new O(this.parseString(t, e, n + 1, s));
          case '[':
            return a = this.parseArray(t, e, n + 1, s), a;
          case '{':
            return a = this.parseObject(t, e, n + 1, s), a;
          case 'n':
            return n + 3 < e ? (a = new N(), s[0] = n + 4) : this._error = 'parse null', a;
          case 't':
            return n + 3 < e ? (a = A.trueValue, s[0] = n + 4) : this._error = 'parse true', a;
          case 'f':
            return n + 4 < e ? (a = A.falseValue, s[0] = n + 5) : this._error = 'illegal \',\' position', a;
          case ',':
            return this._error = 'illegal \',\' position', null;
          case ']':
            return s[0] = n, null;
          case '\n':
            this._lineCount++;
        }
      }
      return this._error = 'illegal end of value', null;
    }
  }, {
    key: "parseString",
    value: function parseString(t, e, i, s) {
      if (this._error) return null;
      if (!t) return this._error = 'string is null', null;
      var r,
        a,
        n = i;
      var o = new g('');
      var l = i;
      for (; n < e; n++) {
        switch (r = t[n], r) {
          case '"':
            return s[0] = n + 1, o.append(t.slice(l), n - l), o.s;
          case '//':
            if (n++, n - 1 > l && o.append(t.slice(l), n - l), l = n + 1, n < e) {
              switch (a = t[n], a) {
                case '\\':
                  o.expansion(1, '\\');
                  break;
                case '"':
                  o.expansion(1, '"');
                  break;
                case '/':
                  o.expansion(1, '/');
                  break;
                case 'b':
                  o.expansion(1, '\b');
                  break;
                case 'f':
                  o.expansion(1, '\f');
                  break;
                case 'n':
                  o.expansion(1, '\n');
                  break;
                case 'r':
                  o.expansion(1, '\r');
                  break;
                case 't':
                  o.expansion(1, '\t');
                  break;
                case 'u':
                  this._error = 'parse string/unicord escape not supported';
              }
            } else {
              this._error = 'parse string/escape error';
            }
        }
      }
      return this._error = 'parse string/illegal end', null;
    }
  }, {
    key: "parseObject",
    value: function parseObject(t, e, i, s) {
      if (this._error) return null;
      if (!t) return this._error = 'buffer is null', null;
      var r = new U();
      var a = '',
        n = i,
        o = '';
      var l = Array(1);
      var h = !1;
      for (; n < e; n++) {
        t: for (; n < e; n++) {
          switch (o = t[n], o) {
            case '"':
              if (a = this.parseString(t, e, n + 1, l), this._error) return null;
              n = l[0], h = !0;
              break t;
            case '}':
              return s[0] = n + 1, r;
            case ':':
              this._error = 'illegal \':\' position';
              break;
            case '\n':
              this._lineCount++;
          }
        }
        if (!h) return this._error = 'key not found', null;
        h = !1;
        t: for (; n < e; n++) {
          switch (o = t[n], o) {
            case ':':
              h = !0, n++;
              break t;
            case '}':
              this._error = 'illegal \'}\' position';
              break;
            case '\n':
              this._lineCount++;
          }
        }
        if (!h) return this._error = '\':\' not found', null;
        var _i10 = this.parseValue(t, e, n, l);
        if (this._error) return null;
        n = l[0], r.put(a, _i10);
        t: for (; n < e; n++) {
          switch (o = t[n], o) {
            case ',':
              break t;
            case '}':
              return s[0] = n + 1, r;
            case '\n':
              this._lineCount++;
          }
        }
      }
      return this._error = 'illegal end of perseObject', null;
    }
  }, {
    key: "parseArray",
    value: function parseArray(t, e, i, s) {
      if (this._error) return null;
      if (!t) return this._error = 'buffer is null', null;
      var r,
        a = new z(),
        n = i;
      var o = new Array(1);
      for (; n < e; n++) {
        var _i11 = this.parseValue(t, e, n, o);
        if (this._error) return null;
        n = o[0], _i11 && a.add(_i11);
        t: for (; n < e; n++) {
          switch (r = t[n], r) {
            case ',':
              break t;
            case ']':
              return s[0] = n + 1, a;
            case '\n':
              ++this._lineCount;
          }
        }
      }
      return a = void 0, this._error = 'illegal end of parseObject', null;
    }
  }], [{
    key: "create",
    value: function create(t, e) {
      var i = new L();
      return i.parseBytes(t, e, i._parseCallback) ? i : (L.delete(i), null);
    }
  }, {
    key: "delete",
    value: function _delete(t) {}
  }, {
    key: "arrayBufferToString",
    value: function arrayBufferToString(t) {
      var e = new Uint8Array(t);
      var i = '';
      for (var _t22 = 0, _s10 = e.length; _t22 < _s10; ++_t22) i += '%' + this.pad(e[_t22].toString(16));
      return i = decodeURIComponent(i), i;
    }
  }, {
    key: "pad",
    value: function pad(t) {
      return t.length < 2 ? '0' + t : t;
    }
  }]);
  return L;
}();
var D = /*#__PURE__*/function (_T) {
  (0,inherits/* default */.A)(D, _T);
  function D(t) {
    var _this2;
    (0,classCallCheck/* default */.A)(this, D);
    _this2 = (0,callSuper/* default */.A)(this, D), _this2._value = t;
    return _this2;
  }
  (0,createClass/* default */.A)(D, [{
    key: "isFloat",
    value: function isFloat() {
      return !0;
    }
  }, {
    key: "getString",
    value: function getString(t, e) {
      return this._value = parseFloat('\0'), this._stringBuffer = '\0', this._stringBuffer;
    }
  }, {
    key: "toInt",
    value: function toInt() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      return parseInt(this._value.toString());
    }
  }, {
    key: "toFloat",
    value: function toFloat() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      return this._value;
    }
  }, {
    key: "equals",
    value: function equals(t) {
      return 'number' == typeof t && !Math.round(t) && t == this._value;
    }
  }]);
  return D;
}(T);
var A = /*#__PURE__*/function (_T2) {
  (0,inherits/* default */.A)(A, _T2);
  function A(t) {
    var _this3;
    (0,classCallCheck/* default */.A)(this, A);
    _this3 = (0,callSuper/* default */.A)(this, A), _this3._boolValue = t;
    return _this3;
  }
  (0,createClass/* default */.A)(A, [{
    key: "isBool",
    value: function isBool() {
      return !0;
    }
  }, {
    key: "toBoolean",
    value: function toBoolean() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : !1;
      return this._boolValue;
    }
  }, {
    key: "getString",
    value: function getString(t, e) {
      return this._stringBuffer = this._boolValue ? 'true' : 'false', this._stringBuffer;
    }
  }, {
    key: "equals",
    value: function equals(t) {
      return 'boolean' == typeof t && t == this._boolValue;
    }
  }, {
    key: "isStatic",
    value: function isStatic() {
      return !0;
    }
  }]);
  return A;
}(T);
var O = /*#__PURE__*/function (_T3) {
  (0,inherits/* default */.A)(O, _T3);
  function O(t) {
    var _this4;
    (0,classCallCheck/* default */.A)(this, O);
    _this4 = (0,callSuper/* default */.A)(this, O), 'string' == typeof t && (_this4._stringBuffer = t), t instanceof g && (_this4._stringBuffer = t.s);
    return _this4;
  }
  (0,createClass/* default */.A)(O, [{
    key: "isString",
    value: function isString() {
      return !0;
    }
  }, {
    key: "getString",
    value: function getString(t, e) {
      return this._stringBuffer;
    }
  }, {
    key: "equals",
    value: function equals(t) {
      return 'string' == typeof t ? this._stringBuffer == t : t instanceof g && this._stringBuffer == t.s;
    }
  }]);
  return O;
}(T);
var k = /*#__PURE__*/function (_O) {
  (0,inherits/* default */.A)(k, _O);
  function k(t, e) {
    var _this5;
    (0,classCallCheck/* default */.A)(this, k);
    _this5 = (0,callSuper/* default */.A)(this, k, [t]), _this5._isStatic = e;
    return _this5;
  }
  (0,createClass/* default */.A)(k, [{
    key: "isStatic",
    value: function isStatic() {
      return this._isStatic;
    }
  }, {
    key: "setErrorNotForClientCall",
    value: function setErrorNotForClientCall(t) {
      return this._stringBuffer = t, this;
    }
  }, {
    key: "isError",
    value: function isError() {
      return !0;
    }
  }]);
  return k;
}(O);
var N = /*#__PURE__*/function (_T4) {
  (0,inherits/* default */.A)(N, _T4);
  function N() {
    var _this6;
    (0,classCallCheck/* default */.A)(this, N);
    _this6 = (0,callSuper/* default */.A)(this, N), _this6._stringBuffer = 'NullValue';
    return _this6;
  }
  (0,createClass/* default */.A)(N, [{
    key: "isNull",
    value: function isNull() {
      return !0;
    }
  }, {
    key: "getString",
    value: function getString(t, e) {
      return this._stringBuffer;
    }
  }, {
    key: "isStatic",
    value: function isStatic() {
      return !0;
    }
  }, {
    key: "setErrorNotForClientCall",
    value: function setErrorNotForClientCall(t) {
      return this._stringBuffer = t, k.nullValue;
    }
  }]);
  return N;
}(T);
var z = /*#__PURE__*/function (_T5) {
  (0,inherits/* default */.A)(z, _T5);
  function z() {
    var _this7;
    (0,classCallCheck/* default */.A)(this, z);
    _this7 = (0,callSuper/* default */.A)(this, z), _this7._array = new e();
    return _this7;
  }
  (0,createClass/* default */.A)(z, [{
    key: "release",
    value: function release() {
      for (var _t23 = this._array.begin(); _t23.notEqual(this._array.end()); _t23.preIncrement()) {
        var _e17 = _t23.ptr();
        _e17 && !_e17.isStatic() && (_e17 = void 0, _e17 = null);
      }
    }
  }, {
    key: "isArray",
    value: function isArray() {
      return !0;
    }
  }, {
    key: "getValueByIndex",
    value: function getValueByIndex(t) {
      if (t < 0 || this._array.getSize() <= t) return T.errorValue.setErrorNotForClientCall('Error: index out of bounds');
      var e = this._array.at(t);
      return null == e ? T.nullValue : e;
    }
  }, {
    key: "getValueByString",
    value: function getValueByString(t) {
      return T.errorValue.setErrorNotForClientCall(R);
    }
  }, {
    key: "getString",
    value: function getString(t, e) {
      var i = e + '[\n';
      for (var _t24 = this._array.begin(); _t24.notEqual(this._array.end()); _t24.increment()) {
        var _i12 = _t24.ptr();
        this._stringBuffer += e + '' + _i12.getString(e + ' ') + '\n';
      }
      return this._stringBuffer = i + e + ']\n', this._stringBuffer;
    }
  }, {
    key: "add",
    value: function add(t) {
      this._array.pushBack(t);
    }
  }, {
    key: "getVector",
    value: function getVector() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
      return this._array;
    }
  }, {
    key: "getSize",
    value: function getSize() {
      return this._array.getSize();
    }
  }]);
  return z;
}(T);
var U = /*#__PURE__*/function (_T6) {
  (0,inherits/* default */.A)(U, _T6);
  function U() {
    var _this8;
    (0,classCallCheck/* default */.A)(this, U);
    _this8 = (0,callSuper/* default */.A)(this, U), _this8._map = new I();
    return _this8;
  }
  (0,createClass/* default */.A)(U, [{
    key: "release",
    value: function release() {
      var t = this._map.begin();
      for (; t.notEqual(this._map.end());) {
        var _e18 = t.ptr().second;
        _e18 && !_e18.isStatic() && (_e18 = void 0, _e18 = null), t.preIncrement();
      }
    }
  }, {
    key: "isMap",
    value: function isMap() {
      return !0;
    }
  }, {
    key: "getValueByString",
    value: function getValueByString(t) {
      if (t instanceof g) {
        var _e19 = this._map.getValue(t.s);
        return null == _e19 ? T.nullValue : _e19;
      }
      for (var _e20 = this._map.begin(); _e20.notEqual(this._map.end()); _e20.preIncrement()) if (_e20.ptr().first == t) return null == _e20.ptr().second ? T.nullValue : _e20.ptr().second;
      return T.nullValue;
    }
  }, {
    key: "getValueByIndex",
    value: function getValueByIndex(t) {
      return T.errorValue.setErrorNotForClientCall(R);
    }
  }, {
    key: "getString",
    value: function getString(t, e) {
      this._stringBuffer = e + '{\n';
      var i = this._map.begin();
      for (; i.notEqual(this._map.end());) {
        var _t25 = i.ptr().first,
          _s11 = i.ptr().second;
        this._stringBuffer += e + ' ' + _t25 + ' : ' + _s11.getString(e + '   ') + ' \n', i.preIncrement();
      }
      return this._stringBuffer += e + '}\n', this._stringBuffer;
    }
  }, {
    key: "getMap",
    value: function getMap(t) {
      return this._map;
    }
  }, {
    key: "put",
    value: function put(t, e) {
      this._map.setValue(t, e);
    }
  }, {
    key: "getKeys",
    value: function getKeys() {
      if (!this._keys) {
        this._keys = new e();
        var _t26 = this._map.begin();
        for (; _t26.notEqual(this._map.end());) {
          var _e21 = _t26.ptr().first;
          this._keys.pushBack(_e21), _t26.preIncrement();
        }
      }
      return this._keys;
    }
  }, {
    key: "getSize",
    value: function getSize() {
      return this._keys.getSize();
    }
  }]);
  return U;
}(T);
var G;
function X(t, e) {
  var i = 0;
  for (var _e22 = 1;; _e22++) {
    var _s12 = t.slice(_e22 - 1, _e22);
    if ('e' == _s12 || '-' == _s12 || 'E' == _s12) continue;
    var _r2 = t.substring(0, _e22),
      _a2 = Number(_r2);
    if (isNaN(_a2)) break;
    i = _e22;
  }
  var s = parseFloat(t);
  return isNaN(s) && (s = NaN), e[0] = t.slice(i), s;
}
!function (t) {
  t.CubismJson = L, t.JsonArray = z, t.JsonBoolean = A, t.JsonError = k, t.JsonFloat = D, t.JsonMap = U, t.JsonNullvalue = N, t.JsonString = O, t.Value = T;
}(G || (G = {}));
var Y = !1,
  j = !1,
  H = null,
  q = null;
var W = Object.freeze({
  vertexOffset: 0,
  vertexStep: 2
});
function J(t) {
  t && (t = void 0);
}
var $ = /*#__PURE__*/function () {
  function $() {
    (0,classCallCheck/* default */.A)(this, $);
  }
  (0,createClass/* default */.A)($, null, [{
    key: "startUp",
    value: function startUp() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
      if (Y) return M('CubismFramework.startUp() is already done.'), Y;
      if (H = t, null != H && Live2DCubismCore.Logging.csmSetLogFunction(H.logFunction), Y = !0, Y) {
        var _t27 = Live2DCubismCore.Version.csmGetVersion(),
          _e23 = (16711680 & _t27) >> 16,
          _i13 = 65535 & _t27,
          _s13 = _t27;
        M('Live2D Cubism Core version: {0}.{1}.{2} ({3})', ('00' + ((4278190080 & _t27) >> 24)).slice(-2), ('00' + _e23).slice(-2), ('0000' + _i13).slice(-4), _s13);
      }
      return M('CubismFramework.startUp() is complete.'), Y;
    }
  }, {
    key: "cleanUp",
    value: function cleanUp() {
      Y = !1, j = !1, H = null, q = null;
    }
  }, {
    key: "initialize",
    value: function initialize() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      C(Y), Y ? j ? v('CubismFramework.initialize() skipped, already initialized.') : (T.staticInitializeNotForClientCall(), q = new _(), Live2DCubismCore.Memory.initializeAmountOfMemory(t), j = !0, M('CubismFramework.initialize() is complete.')) : v('CubismFramework is not started.');
    }
  }, {
    key: "dispose",
    value: function dispose() {
      C(Y), Y ? j ? (T.staticReleaseNotForClientCall(), q.release(), q = null, p.staticRelease(), j = !1, M('CubismFramework.dispose() is complete.')) : v('CubismFramework.dispose() skipped, not initialized.') : v('CubismFramework is not started.');
    }
  }, {
    key: "isStarted",
    value: function isStarted() {
      return Y;
    }
  }, {
    key: "isInitialized",
    value: function isInitialized() {
      return j;
    }
  }, {
    key: "coreLogFunction",
    value: function coreLogFunction(t) {
      Live2DCubismCore.Logging.csmGetLogFunction() && Live2DCubismCore.Logging.csmGetLogFunction()(t);
    }
  }, {
    key: "getLoggingLevel",
    value: function getLoggingLevel() {
      return null != H ? H.loggingLevel : K.LogLevel_Off;
    }
  }, {
    key: "getIdManager",
    value: function getIdManager() {
      return q;
    }
  }]);
  return $;
}();
var Z = /*#__PURE__*/(0,createClass/* default */.A)(function Z() {
  (0,classCallCheck/* default */.A)(this, Z);
});
var K, Q;
!function (t) {
  t[t.LogLevel_Verbose = 0] = 'LogLevel_Verbose', t[t.LogLevel_Debug = 1] = 'LogLevel_Debug', t[t.LogLevel_Info = 2] = 'LogLevel_Info', t[t.LogLevel_Warning = 3] = 'LogLevel_Warning', t[t.LogLevel_Error = 4] = 'LogLevel_Error', t[t.LogLevel_Off = 5] = 'LogLevel_Off';
}(K || (K = {})), function (t) {
  t.Constant = W, t.csmDelete = J, t.CubismFramework = $;
}(Q || (Q = {}));
var tt = '../../Resources/',
  et = ['Haru', 'Hiyori', 'Mark', 'Natori', 'Rice', 'Mao', 'Wanko'],
  it = et.length,
  st = 'Body',
  rt = K.LogLevel_Verbose;
var at = /*#__PURE__*/function () {
  function at() {
    (0,classCallCheck/* default */.A)(this, at);
  }
  (0,createClass/* default */.A)(at, null, [{
    key: "loadFileAsBytes",
    value: function loadFileAsBytes(t, e) {
      fetch(t).then(function (t) {
        return t.arrayBuffer();
      }).then(function (t) {
        return e(t, t.byteLength);
      });
    }
  }, {
    key: "getDeltaTime",
    value: function getDeltaTime() {
      return this.deltaTime;
    }
  }, {
    key: "updateTime",
    value: function updateTime() {
      this.currentFrame = Date.now(), this.deltaTime = (this.currentFrame - this.lastFrame) / 1e3, this.lastFrame = this.currentFrame;
    }
  }, {
    key: "printMessage",
    value: function printMessage(t) {
      console.trace(t);
    }
  }]);
  return at;
}();
at.lastUpdate = Date.now(), at.currentFrame = 0, at.lastFrame = 0, at.deltaTime = 0;
var nt = /*#__PURE__*/function () {
  function nt() {
    (0,classCallCheck/* default */.A)(this, nt);
    this._gl = null, this._gl = null;
  }
  (0,createClass/* default */.A)(nt, [{
    key: "initialize",
    value: function initialize(t) {
      return this._gl = t.getContext('webgl2'), !!this._gl || (alert('Cannot initialize WebGL. This browser does not support.'), this._gl = null, !1);
    }
  }, {
    key: "release",
    value: function release() {}
  }, {
    key: "getGl",
    value: function getGl() {
      return this._gl;
    }
  }]);
  return nt;
}();
var ot = Object.freeze({
  HitAreaPrefix: 'HitArea',
  HitAreaHead: 'Head',
  HitAreaBody: 'Body',
  PartsIdCore: 'Parts01Core',
  PartsArmPrefix: 'Parts01Arm_',
  PartsArmLPrefix: 'Parts01ArmL_',
  PartsArmRPrefix: 'Parts01ArmR_',
  ParamAngleX: 'ParamAngleX',
  ParamAngleY: 'ParamAngleY',
  ParamAngleZ: 'ParamAngleZ',
  ParamEyeLOpen: 'ParamEyeLOpen',
  ParamEyeLSmile: 'ParamEyeLSmile',
  ParamEyeROpen: 'ParamEyeROpen',
  ParamEyeRSmile: 'ParamEyeRSmile',
  ParamEyeBallX: 'ParamEyeBallX',
  ParamEyeBallY: 'ParamEyeBallY',
  ParamEyeBallForm: 'ParamEyeBallForm',
  ParamBrowLY: 'ParamBrowLY',
  ParamBrowRY: 'ParamBrowRY',
  ParamBrowLX: 'ParamBrowLX',
  ParamBrowRX: 'ParamBrowRX',
  ParamBrowLAngle: 'ParamBrowLAngle',
  ParamBrowRAngle: 'ParamBrowRAngle',
  ParamBrowLForm: 'ParamBrowLForm',
  ParamBrowRForm: 'ParamBrowRForm',
  ParamMouthForm: 'ParamMouthForm',
  ParamMouthOpenY: 'ParamMouthOpenY',
  ParamCheek: 'ParamCheek',
  ParamBodyAngleX: 'ParamBodyAngleX',
  ParamBodyAngleY: 'ParamBodyAngleY',
  ParamBodyAngleZ: 'ParamBodyAngleZ',
  ParamBreath: 'ParamBreath',
  ParamArmLA: 'ParamArmLA',
  ParamArmRA: 'ParamArmRA',
  ParamArmLB: 'ParamArmLB',
  ParamArmRB: 'ParamArmRB',
  ParamHandL: 'ParamHandL',
  ParamHandR: 'ParamHandR',
  ParamHairFront: 'ParamHairFront',
  ParamHairSide: 'ParamHairSide',
  ParamHairBack: 'ParamHairBack',
  ParamHairFluffy: 'ParamHairFluffy',
  ParamShoulderY: 'ParamShoulderY',
  ParamBustX: 'ParamBustX',
  ParamBustY: 'ParamBustY',
  ParamBaseX: 'ParamBaseX',
  ParamBaseY: 'ParamBaseY',
  ParamNONE: 'NONE:'
});
var lt, ht, ut, gt, dt, _t, ct;
!function (t) {
  t.HitAreaBody = ot.HitAreaBody, t.HitAreaHead = ot.HitAreaHead, t.HitAreaPrefix = ot.HitAreaPrefix, t.ParamAngleX = ot.ParamAngleX, t.ParamAngleY = ot.ParamAngleY, t.ParamAngleZ = ot.ParamAngleZ, t.ParamArmLA = ot.ParamArmLA, t.ParamArmLB = ot.ParamArmLB, t.ParamArmRA = ot.ParamArmRA, t.ParamArmRB = ot.ParamArmRB, t.ParamBaseX = ot.ParamBaseX, t.ParamBaseY = ot.ParamBaseY, t.ParamBodyAngleX = ot.ParamBodyAngleX, t.ParamBodyAngleY = ot.ParamBodyAngleY, t.ParamBodyAngleZ = ot.ParamBodyAngleZ, t.ParamBreath = ot.ParamBreath, t.ParamBrowLAngle = ot.ParamBrowLAngle, t.ParamBrowLForm = ot.ParamBrowLForm, t.ParamBrowLX = ot.ParamBrowLX, t.ParamBrowLY = ot.ParamBrowLY, t.ParamBrowRAngle = ot.ParamBrowRAngle, t.ParamBrowRForm = ot.ParamBrowRForm, t.ParamBrowRX = ot.ParamBrowRX, t.ParamBrowRY = ot.ParamBrowRY, t.ParamBustX = ot.ParamBustX, t.ParamBustY = ot.ParamBustY, t.ParamCheek = ot.ParamCheek, t.ParamEyeBallForm = ot.ParamEyeBallForm, t.ParamEyeBallX = ot.ParamEyeBallX, t.ParamEyeBallY = ot.ParamEyeBallY, t.ParamEyeLOpen = ot.ParamEyeLOpen, t.ParamEyeLSmile = ot.ParamEyeLSmile, t.ParamEyeROpen = ot.ParamEyeROpen, t.ParamEyeRSmile = ot.ParamEyeRSmile, t.ParamHairBack = ot.ParamHairBack, t.ParamHairFluffy = ot.ParamHairFluffy, t.ParamHairFront = ot.ParamHairFront, t.ParamHairSide = ot.ParamHairSide, t.ParamHandL = ot.ParamHandL, t.ParamHandR = ot.ParamHandR, t.ParamMouthForm = ot.ParamMouthForm, t.ParamMouthOpenY = ot.ParamMouthOpenY, t.ParamNONE = ot.ParamNONE, t.ParamShoulderY = ot.ParamShoulderY, t.PartsArmLPrefix = ot.PartsArmLPrefix, t.PartsArmPrefix = ot.PartsArmPrefix, t.PartsArmRPrefix = ot.PartsArmRPrefix, t.PartsIdCore = ot.PartsIdCore;
}(lt || (lt = {}));
var mt = /*#__PURE__*/(0,createClass/* default */.A)(function mt() {
  (0,classCallCheck/* default */.A)(this, mt);
});
(ht || (ht = {})).ICubismModelSetting = mt, function (t) {
  t[t.FrequestNode_Groups = 0] = 'FrequestNode_Groups', t[t.FrequestNode_Moc = 1] = 'FrequestNode_Moc', t[t.FrequestNode_Motions = 2] = 'FrequestNode_Motions', t[t.FrequestNode_Expressions = 3] = 'FrequestNode_Expressions', t[t.FrequestNode_Textures = 4] = 'FrequestNode_Textures', t[t.FrequestNode_Physics = 5] = 'FrequestNode_Physics', t[t.FrequestNode_Pose = 6] = 'FrequestNode_Pose', t[t.FrequestNode_HitAreas = 7] = 'FrequestNode_HitAreas';
}(ut || (ut = {}));
var pt = /*#__PURE__*/function (_mt) {
  (0,inherits/* default */.A)(pt, _mt);
  function pt(t, i) {
    var _this9;
    (0,classCallCheck/* default */.A)(this, pt);
    _this9 = (0,callSuper/* default */.A)(this, pt), _this9.version = 'Version', _this9.fileReferences = 'FileReferences', _this9.groups = 'Groups', _this9.layout = 'Layout', _this9.hitAreas = 'HitAreas', _this9.moc = 'Moc', _this9.textures = 'Textures', _this9.physics = 'Physics', _this9.pose = 'Pose', _this9.expressions = 'Expressions', _this9.motions = 'Motions', _this9.userData = 'UserData', _this9.name = 'Name', _this9.filePath = 'File', _this9.id = 'Id', _this9.ids = 'Ids', _this9.target = 'Target', _this9.idle = 'Idle', _this9.tapBody = 'TapBody', _this9.pinchIn = 'PinchIn', _this9.pinchOut = 'PinchOut', _this9.shake = 'Shake', _this9.flickHead = 'FlickHead', _this9.parameter = 'Parameter', _this9.soundPath = 'Sound', _this9.fadeInTime = 'FadeInTime', _this9.fadeOutTime = 'FadeOutTime', _this9.centerX = 'CenterX', _this9.centerY = 'CenterY', _this9.x = 'X', _this9.y = 'Y', _this9.width = 'Width', _this9.height = 'Height', _this9.lipSync = 'LipSync', _this9.eyeBlink = 'EyeBlink', _this9.initParameter = 'init_param', _this9.initPartsVisible = 'init_parts_visible', _this9.val = 'val', _this9._json = L.create(t, i), _this9.getJson() && (_this9._jsonValue = new e(), _this9._jsonValue.pushBack(_this9.getJson().getRoot().getValueByString(_this9.groups)), _this9._jsonValue.pushBack(_this9.getJson().getRoot().getValueByString(_this9.fileReferences).getValueByString(_this9.moc)), _this9._jsonValue.pushBack(_this9.getJson().getRoot().getValueByString(_this9.fileReferences).getValueByString(_this9.motions)), _this9._jsonValue.pushBack(_this9.getJson().getRoot().getValueByString(_this9.fileReferences).getValueByString(_this9.expressions)), _this9._jsonValue.pushBack(_this9.getJson().getRoot().getValueByString(_this9.fileReferences).getValueByString(_this9.textures)), _this9._jsonValue.pushBack(_this9.getJson().getRoot().getValueByString(_this9.fileReferences).getValueByString(_this9.physics)), _this9._jsonValue.pushBack(_this9.getJson().getRoot().getValueByString(_this9.fileReferences).getValueByString(_this9.pose)), _this9._jsonValue.pushBack(_this9.getJson().getRoot().getValueByString(_this9.hitAreas)));
    return _this9;
  }
  (0,createClass/* default */.A)(pt, [{
    key: "release",
    value: function release() {
      L.delete(this._json), this._jsonValue = null;
    }
  }, {
    key: "getJson",
    value: function getJson() {
      return this._json;
    }
  }, {
    key: "getModelFileName",
    value: function getModelFileName() {
      return this.isExistModelFile() ? this._jsonValue.at(ut.FrequestNode_Moc).getRawString() : '';
    }
  }, {
    key: "getTextureCount",
    value: function getTextureCount() {
      return this.isExistTextureFiles() ? this._jsonValue.at(ut.FrequestNode_Textures).getSize() : 0;
    }
  }, {
    key: "getTextureDirectory",
    value: function getTextureDirectory() {
      var t = this._jsonValue.at(ut.FrequestNode_Textures).getValueByIndex(0).getRawString().split('/'),
        e = t.length - 1;
      var i = '';
      for (var _s14 = 0; _s14 < e; _s14++) i += t[_s14], _s14 < e - 1 && (i += '/');
      return i;
    }
  }, {
    key: "getTextureFileName",
    value: function getTextureFileName(t) {
      return this._jsonValue.at(ut.FrequestNode_Textures).getValueByIndex(t).getRawString();
    }
  }, {
    key: "getHitAreasCount",
    value: function getHitAreasCount() {
      return this.isExistHitAreas() ? this._jsonValue.at(ut.FrequestNode_HitAreas).getSize() : 0;
    }
  }, {
    key: "getHitAreaId",
    value: function getHitAreaId(t) {
      return $.getIdManager().getId(this._jsonValue.at(ut.FrequestNode_HitAreas).getValueByIndex(t).getValueByString(this.id).getRawString());
    }
  }, {
    key: "getHitAreaName",
    value: function getHitAreaName(t) {
      return this._jsonValue.at(ut.FrequestNode_HitAreas).getValueByIndex(t).getValueByString(this.name).getRawString();
    }
  }, {
    key: "getPhysicsFileName",
    value: function getPhysicsFileName() {
      return this.isExistPhysicsFile() ? this._jsonValue.at(ut.FrequestNode_Physics).getRawString() : '';
    }
  }, {
    key: "getPoseFileName",
    value: function getPoseFileName() {
      return this.isExistPoseFile() ? this._jsonValue.at(ut.FrequestNode_Pose).getRawString() : '';
    }
  }, {
    key: "getExpressionCount",
    value: function getExpressionCount() {
      return this.isExistExpressionFile() ? this._jsonValue.at(ut.FrequestNode_Expressions).getSize() : 0;
    }
  }, {
    key: "getExpressionName",
    value: function getExpressionName(t) {
      return this._jsonValue.at(ut.FrequestNode_Expressions).getValueByIndex(t).getValueByString(this.name).getRawString();
    }
  }, {
    key: "getExpressionFileName",
    value: function getExpressionFileName(t) {
      return this._jsonValue.at(ut.FrequestNode_Expressions).getValueByIndex(t).getValueByString(this.filePath).getRawString();
    }
  }, {
    key: "getMotionGroupCount",
    value: function getMotionGroupCount() {
      return this.isExistMotionGroups() ? this._jsonValue.at(ut.FrequestNode_Motions).getKeys().getSize() : 0;
    }
  }, {
    key: "getMotionGroupName",
    value: function getMotionGroupName(t) {
      return this.isExistMotionGroups() ? this._jsonValue.at(ut.FrequestNode_Motions).getKeys().at(t) : null;
    }
  }, {
    key: "getMotionCount",
    value: function getMotionCount(t) {
      return this.isExistMotionGroupName(t) ? this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t).getSize() : 0;
    }
  }, {
    key: "getMotionFileName",
    value: function getMotionFileName(t, e) {
      return this.isExistMotionGroupName(t) ? this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t).getValueByIndex(e).getValueByString(this.filePath).getRawString() : '';
    }
  }, {
    key: "getMotionSoundFileName",
    value: function getMotionSoundFileName(t, e) {
      return this.isExistMotionSoundFile(t, e) ? this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t).getValueByIndex(e).getValueByString(this.soundPath).getRawString() : '';
    }
  }, {
    key: "getMotionFadeInTimeValue",
    value: function getMotionFadeInTimeValue(t, e) {
      return this.isExistMotionFadeIn(t, e) ? this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t).getValueByIndex(e).getValueByString(this.fadeInTime).toFloat() : -1;
    }
  }, {
    key: "getMotionFadeOutTimeValue",
    value: function getMotionFadeOutTimeValue(t, e) {
      return this.isExistMotionFadeOut(t, e) ? this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t).getValueByIndex(e).getValueByString(this.fadeOutTime).toFloat() : -1;
    }
  }, {
    key: "getUserDataFile",
    value: function getUserDataFile() {
      return this.isExistUserDataFile() ? this.getJson().getRoot().getValueByString(this.fileReferences).getValueByString(this.userData).getRawString() : '';
    }
  }, {
    key: "getLayoutMap",
    value: function getLayoutMap(t) {
      var e = this.getJson().getRoot().getValueByString(this.layout).getMap();
      if (null == e) return !1;
      var i = !1;
      for (var _s15 = e.begin(); _s15.notEqual(e.end()); _s15.preIncrement()) t.setValue(_s15.ptr().first, _s15.ptr().second.toFloat()), i = !0;
      return i;
    }
  }, {
    key: "getEyeBlinkParameterCount",
    value: function getEyeBlinkParameterCount() {
      if (!this.isExistEyeBlinkParameters()) return 0;
      var t = 0;
      for (var _e24 = 0; _e24 < this._jsonValue.at(ut.FrequestNode_Groups).getSize(); _e24++) {
        var _i14 = this._jsonValue.at(ut.FrequestNode_Groups).getValueByIndex(_e24);
        if (!_i14.isNull() && !_i14.isError() && _i14.getValueByString(this.name).getRawString() == this.eyeBlink) {
          t = _i14.getValueByString(this.ids).getVector().getSize();
          break;
        }
      }
      return t;
    }
  }, {
    key: "getEyeBlinkParameterId",
    value: function getEyeBlinkParameterId(t) {
      if (!this.isExistEyeBlinkParameters()) return null;
      for (var _e25 = 0; _e25 < this._jsonValue.at(ut.FrequestNode_Groups).getSize(); _e25++) {
        var _i15 = this._jsonValue.at(ut.FrequestNode_Groups).getValueByIndex(_e25);
        if (!_i15.isNull() && !_i15.isError() && _i15.getValueByString(this.name).getRawString() == this.eyeBlink) return $.getIdManager().getId(_i15.getValueByString(this.ids).getValueByIndex(t).getRawString());
      }
      return null;
    }
  }, {
    key: "getLipSyncParameterCount",
    value: function getLipSyncParameterCount() {
      if (!this.isExistLipSyncParameters()) return 0;
      var t = 0;
      for (var _e26 = 0; _e26 < this._jsonValue.at(ut.FrequestNode_Groups).getSize(); _e26++) {
        var _i16 = this._jsonValue.at(ut.FrequestNode_Groups).getValueByIndex(_e26);
        if (!_i16.isNull() && !_i16.isError() && _i16.getValueByString(this.name).getRawString() == this.lipSync) {
          t = _i16.getValueByString(this.ids).getVector().getSize();
          break;
        }
      }
      return t;
    }
  }, {
    key: "getLipSyncParameterId",
    value: function getLipSyncParameterId(t) {
      if (!this.isExistLipSyncParameters()) return null;
      for (var _e27 = 0; _e27 < this._jsonValue.at(ut.FrequestNode_Groups).getSize(); _e27++) {
        var _i17 = this._jsonValue.at(ut.FrequestNode_Groups).getValueByIndex(_e27);
        if (!_i17.isNull() && !_i17.isError() && _i17.getValueByString(this.name).getRawString() == this.lipSync) return $.getIdManager().getId(_i17.getValueByString(this.ids).getValueByIndex(t).getRawString());
      }
      return null;
    }
  }, {
    key: "isExistModelFile",
    value: function isExistModelFile() {
      var t = this._jsonValue.at(ut.FrequestNode_Moc);
      return !t.isNull() && !t.isError();
    }
  }, {
    key: "isExistTextureFiles",
    value: function isExistTextureFiles() {
      var t = this._jsonValue.at(ut.FrequestNode_Textures);
      return !t.isNull() && !t.isError();
    }
  }, {
    key: "isExistHitAreas",
    value: function isExistHitAreas() {
      var t = this._jsonValue.at(ut.FrequestNode_HitAreas);
      return !t.isNull() && !t.isError();
    }
  }, {
    key: "isExistPhysicsFile",
    value: function isExistPhysicsFile() {
      var t = this._jsonValue.at(ut.FrequestNode_Physics);
      return !t.isNull() && !t.isError();
    }
  }, {
    key: "isExistPoseFile",
    value: function isExistPoseFile() {
      var t = this._jsonValue.at(ut.FrequestNode_Pose);
      return !t.isNull() && !t.isError();
    }
  }, {
    key: "isExistExpressionFile",
    value: function isExistExpressionFile() {
      var t = this._jsonValue.at(ut.FrequestNode_Expressions);
      return !t.isNull() && !t.isError();
    }
  }, {
    key: "isExistMotionGroups",
    value: function isExistMotionGroups() {
      var t = this._jsonValue.at(ut.FrequestNode_Motions);
      return !t.isNull() && !t.isError();
    }
  }, {
    key: "isExistMotionGroupName",
    value: function isExistMotionGroupName(t) {
      var e = this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t);
      return !e.isNull() && !e.isError();
    }
  }, {
    key: "isExistMotionSoundFile",
    value: function isExistMotionSoundFile(t, e) {
      var i = this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t).getValueByIndex(e).getValueByString(this.soundPath);
      return !i.isNull() && !i.isError();
    }
  }, {
    key: "isExistMotionFadeIn",
    value: function isExistMotionFadeIn(t, e) {
      var i = this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t).getValueByIndex(e).getValueByString(this.fadeInTime);
      return !i.isNull() && !i.isError();
    }
  }, {
    key: "isExistMotionFadeOut",
    value: function isExistMotionFadeOut(t, e) {
      var i = this._jsonValue.at(ut.FrequestNode_Motions).getValueByString(t).getValueByIndex(e).getValueByString(this.fadeOutTime);
      return !i.isNull() && !i.isError();
    }
  }, {
    key: "isExistUserDataFile",
    value: function isExistUserDataFile() {
      var t = this.getJson().getRoot().getValueByString(this.fileReferences).getValueByString(this.userData);
      return !t.isNull() && !t.isError();
    }
  }, {
    key: "isExistEyeBlinkParameters",
    value: function isExistEyeBlinkParameters() {
      if (this._jsonValue.at(ut.FrequestNode_Groups).isNull() || this._jsonValue.at(ut.FrequestNode_Groups).isError()) return !1;
      for (var _t28 = 0; _t28 < this._jsonValue.at(ut.FrequestNode_Groups).getSize(); ++_t28) if (this._jsonValue.at(ut.FrequestNode_Groups).getValueByIndex(_t28).getValueByString(this.name).getRawString() == this.eyeBlink) return !0;
      return !1;
    }
  }, {
    key: "isExistLipSyncParameters",
    value: function isExistLipSyncParameters() {
      if (this._jsonValue.at(ut.FrequestNode_Groups).isNull() || this._jsonValue.at(ut.FrequestNode_Groups).isError()) return !1;
      for (var _t29 = 0; _t29 < this._jsonValue.at(ut.FrequestNode_Groups).getSize(); ++_t29) if (this._jsonValue.at(ut.FrequestNode_Groups).getValueByIndex(_t29).getValueByString(this.name).getRawString() == this.lipSync) return !0;
      return !1;
    }
  }]);
  return pt;
}(mt);
!function (t) {
  t.CubismModelSettingJson = pt, t.FrequestNode = ut;
}(gt || (gt = {}));
var ft = /*#__PURE__*/function () {
  function ft() {
    (0,classCallCheck/* default */.A)(this, ft);
    this._currentTime = 0;
  }
  (0,createClass/* default */.A)(ft, [{
    key: "setParameters",
    value: function setParameters(t) {
      this._breathParameters = t;
    }
  }, {
    key: "getParameters",
    value: function getParameters() {
      return this._breathParameters;
    }
  }, {
    key: "updateParameters",
    value: function updateParameters(t, e) {
      this._currentTime += e;
      var i = 2 * this._currentTime * Math.PI;
      for (var _e28 = 0; _e28 < this._breathParameters.getSize(); ++_e28) {
        var _s16 = this._breathParameters.at(_e28);
        t.addParameterValueById(_s16.parameterId, _s16.offset + _s16.peak * Math.sin(i / _s16.cycle), _s16.weight);
      }
    }
  }], [{
    key: "create",
    value: function create() {
      return new ft();
    }
  }, {
    key: "delete",
    value: function _delete(t) {}
  }]);
  return ft;
}();
var yt = /*#__PURE__*/(0,createClass/* default */.A)(function yt(t, e, i, s, r) {
  (0,classCallCheck/* default */.A)(this, yt);
  this.parameterId = null == t ? null : t, this.offset = null == e ? 0 : e, this.peak = null == i ? 0 : i, this.cycle = null == s ? 0 : s, this.weight = null == r ? 0 : r;
});
!function (t) {
  t.BreathParameterData = yt, t.CubismBreath = ft;
}(dt || (dt = {}));
var St = /*#__PURE__*/function () {
  function St(t) {
    (0,classCallCheck/* default */.A)(this, St);
    if (this._blinkingState = _t.EyeState_First, this._nextBlinkingTime = 0, this._stateStartTimeSeconds = 0, this._blinkingIntervalSeconds = 4, this._closingSeconds = .1, this._closedSeconds = .05, this._openingSeconds = .15, this._userTimeSeconds = 0, this._parameterIds = new e(), null != t) for (var _e29 = 0; _e29 < t.getEyeBlinkParameterCount(); ++_e29) this._parameterIds.pushBack(t.getEyeBlinkParameterId(_e29));
  }
  (0,createClass/* default */.A)(St, [{
    key: "setBlinkingInterval",
    value: function setBlinkingInterval(t) {
      this._blinkingIntervalSeconds = t;
    }
  }, {
    key: "setBlinkingSetting",
    value: function setBlinkingSetting(t, e, i) {
      this._closingSeconds = t, this._closedSeconds = e, this._openingSeconds = i;
    }
  }, {
    key: "setParameterIds",
    value: function setParameterIds(t) {
      this._parameterIds = t;
    }
  }, {
    key: "getParameterIds",
    value: function getParameterIds() {
      return this._parameterIds;
    }
  }, {
    key: "updateParameters",
    value: function updateParameters(t, e) {
      var i;
      this._userTimeSeconds += e;
      var s = 0;
      switch (this._blinkingState) {
        case _t.EyeState_Closing:
          s = (this._userTimeSeconds - this._stateStartTimeSeconds) / this._closingSeconds, s >= 1 && (s = 1, this._blinkingState = _t.EyeState_Closed, this._stateStartTimeSeconds = this._userTimeSeconds), i = 1 - s;
          break;
        case _t.EyeState_Closed:
          s = (this._userTimeSeconds - this._stateStartTimeSeconds) / this._closedSeconds, s >= 1 && (this._blinkingState = _t.EyeState_Opening, this._stateStartTimeSeconds = this._userTimeSeconds), i = 0;
          break;
        case _t.EyeState_Opening:
          s = (this._userTimeSeconds - this._stateStartTimeSeconds) / this._openingSeconds, s >= 1 && (s = 1, this._blinkingState = _t.EyeState_Interval, this._nextBlinkingTime = this.determinNextBlinkingTiming()), i = s;
          break;
        case _t.EyeState_Interval:
          this._nextBlinkingTime < this._userTimeSeconds && (this._blinkingState = _t.EyeState_Closing, this._stateStartTimeSeconds = this._userTimeSeconds), i = 1;
          break;
        case _t.EyeState_First:
        default:
          this._blinkingState = _t.EyeState_Interval, this._nextBlinkingTime = this.determinNextBlinkingTiming(), i = 1;
      }
      St.CloseIfZero || (i = -i);
      for (var _e30 = 0; _e30 < this._parameterIds.getSize(); ++_e30) t.setParameterValueById(this._parameterIds.at(_e30), i);
    }
  }, {
    key: "determinNextBlinkingTiming",
    value: function determinNextBlinkingTiming() {
      var t = Math.random();
      return this._userTimeSeconds + t * (2 * this._blinkingIntervalSeconds - 1);
    }
  }], [{
    key: "create",
    value: function create() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
      return new St(t);
    }
  }, {
    key: "delete",
    value: function _delete(t) {}
  }]);
  return St;
}();
St.CloseIfZero = !0, function (t) {
  t[t.EyeState_First = 0] = 'EyeState_First', t[t.EyeState_Interval = 1] = 'EyeState_Interval', t[t.EyeState_Closing = 2] = 'EyeState_Closing', t[t.EyeState_Closed = 3] = 'EyeState_Closed', t[t.EyeState_Opening = 4] = 'EyeState_Opening';
}(_t || (_t = {})), function (t) {
  t.CubismEyeBlink = St, t.EyeState = _t;
}(ct || (ct = {}));
var Ct = 'FadeInTime',
  xt = 'Link';
var Mt = /*#__PURE__*/function () {
  function Mt() {
    (0,classCallCheck/* default */.A)(this, Mt);
    this._fadeTimeSeconds = .5, this._lastModel = null, this._partGroups = new e(), this._partGroupCounts = new e();
  }
  (0,createClass/* default */.A)(Mt, [{
    key: "updateParameters",
    value: function updateParameters(t, e) {
      t != this._lastModel && this.reset(t), this._lastModel = t, e < 0 && (e = 0);
      var i = 0;
      for (var _s17 = 0; _s17 < this._partGroupCounts.getSize(); _s17++) {
        var _r3 = this._partGroupCounts.at(_s17);
        this.doFade(t, e, i, _r3), i += _r3;
      }
      this.copyPartOpacities(t);
    }
  }, {
    key: "reset",
    value: function reset(t) {
      var e = 0;
      for (var _i18 = 0; _i18 < this._partGroupCounts.getSize(); ++_i18) {
        var _s18 = this._partGroupCounts.at(_i18);
        for (var _i19 = e; _i19 < e + _s18; ++_i19) {
          this._partGroups.at(_i19).initialize(t);
          var _s19 = this._partGroups.at(_i19).partIndex,
            _r4 = this._partGroups.at(_i19).parameterIndex;
          if (!(_s19 < 0)) {
            t.setPartOpacityByIndex(_s19, _i19 == e ? 1 : 0), t.setParameterValueByIndex(_r4, _i19 == e ? 1 : 0);
            for (var _e31 = 0; _e31 < this._partGroups.at(_i19).link.getSize(); ++_e31) this._partGroups.at(_i19).link.at(_e31).initialize(t);
          }
        }
        e += _s18;
      }
    }
  }, {
    key: "copyPartOpacities",
    value: function copyPartOpacities(t) {
      for (var _e32 = 0; _e32 < this._partGroups.getSize(); ++_e32) {
        var _i20 = this._partGroups.at(_e32);
        if (0 == _i20.link.getSize()) continue;
        var _s20 = this._partGroups.at(_e32).partIndex,
          _r5 = t.getPartOpacityByIndex(_s20);
        for (var _e33 = 0; _e33 < _i20.link.getSize(); ++_e33) {
          var _s21 = _i20.link.at(_e33).partIndex;
          _s21 < 0 || t.setPartOpacityByIndex(_s21, _r5);
        }
      }
    }
  }, {
    key: "doFade",
    value: function doFade(t, e, i, s) {
      var r = -1,
        a = 1;
      var n = .5;
      for (var _n = i; _n < i + s; ++_n) {
        var _i21 = this._partGroups.at(_n).partIndex,
          _s22 = this._partGroups.at(_n).parameterIndex;
        if (t.getParameterValueByIndex(_s22) > .001) {
          if (r >= 0) break;
          if (r = _n, 0 == this._fadeTimeSeconds) {
            a = 1;
            continue;
          }
          a = t.getPartOpacityByIndex(_i21), a += e / this._fadeTimeSeconds, a > 1 && (a = 1);
        }
      }
      r < 0 && (r = 0, a = 1);
      for (var _e34 = i; _e34 < i + s; ++_e34) {
        var _i22 = this._partGroups.at(_e34).partIndex;
        if (r == _e34) {
          t.setPartOpacityByIndex(_i22, a);
        } else {
          var _e35 = void 0,
            _s23 = t.getPartOpacityByIndex(_i22);
          _e35 = a < n ? -.5 * a / n + 1 : (1 - a) * n / .5;
          (1 - _e35) * (1 - a) > .15 && (_e35 = 1 - .15 / (1 - a)), _s23 > _e35 && (_s23 = _e35), t.setPartOpacityByIndex(_i22, _s23);
        }
      }
    }
  }], [{
    key: "create",
    value: function create(t, e) {
      var i = L.create(t, e);
      if (!i) return null;
      var s = new Mt(),
        r = i.getRoot();
      r.getValueByString(Ct).isNull() || (s._fadeTimeSeconds = r.getValueByString(Ct).toFloat(.5), s._fadeTimeSeconds < 0 && (s._fadeTimeSeconds = .5));
      var a = r.getValueByString('Groups'),
        n = a.getSize();
      for (var _t30 = 0; _t30 < n; ++_t30) {
        var _e36 = a.getValueByIndex(_t30),
          _i23 = _e36.getSize();
        var _r6 = 0;
        for (var _t31 = 0; _t31 < _i23; ++_t31) {
          var _i24 = _e36.getValueByIndex(_t31),
            _a3 = new vt(),
            _n2 = $.getIdManager().getId(_i24.getValueByString('Id').getRawString());
          if (_a3.partId = _n2, !_i24.getValueByString(xt).isNull()) {
            var _t32 = _i24.getValueByString(xt),
              _e37 = _t32.getSize();
            for (var _i25 = 0; _i25 < _e37; ++_i25) {
              var _e38 = new vt(),
                _s24 = $.getIdManager().getId(_t32.getValueByIndex(_i25).getString());
              _e38.partId = _s24, _a3.link.pushBack(_e38);
            }
          }
          s._partGroups.pushBack(_a3.clone()), ++_r6;
        }
        s._partGroupCounts.pushBack(_r6);
      }
      return L.delete(i), s;
    }
  }, {
    key: "delete",
    value: function _delete(t) {}
  }]);
  return Mt;
}();
var vt = /*#__PURE__*/function () {
  function vt(t) {
    (0,classCallCheck/* default */.A)(this, vt);
    if (this.parameterIndex = 0, this.partIndex = 0, this.link = new e(), null != t) {
      this.partId = t.partId;
      for (var _e39 = t.link.begin(); _e39.notEqual(t.link.end()); _e39.preIncrement()) this.link.pushBack(_e39.ptr().clone());
    }
  }
  (0,createClass/* default */.A)(vt, [{
    key: "assignment",
    value: function assignment(t) {
      this.partId = t.partId;
      for (var _e40 = t.link.begin(); _e40.notEqual(t.link.end()); _e40.preIncrement()) this.link.pushBack(_e40.ptr().clone());
      return this;
    }
  }, {
    key: "initialize",
    value: function initialize(t) {
      this.parameterIndex = t.getParameterIndex(this.partId), this.partIndex = t.getPartIndex(this.partId), t.setParameterValueByIndex(this.parameterIndex, 1);
    }
  }, {
    key: "clone",
    value: function clone() {
      var t = new vt();
      t.partId = this.partId, t.parameterIndex = this.parameterIndex, t.partIndex = this.partIndex, t.link = new e();
      for (var _e41 = this.link.begin(); _e41.notEqual(this.link.end()); _e41.increment()) t.link.pushBack(_e41.ptr().clone());
      return t;
    }
  }]);
  return vt;
}();
var bt, Pt, Bt, wt;
!function (t) {
  t.CubismPose = Mt, t.PartData = vt;
}(bt || (bt = {}));
var Ft = /*#__PURE__*/function (_c) {
  (0,inherits/* default */.A)(Ft, _c);
  function Ft(t, e) {
    var _this10;
    (0,classCallCheck/* default */.A)(this, Ft);
    _this10 = (0,callSuper/* default */.A)(this, Ft), _this10._width = void 0 !== t ? t : 0, _this10._height = void 0 !== e ? e : 0, _this10.setHeight(2);
    return _this10;
  }
  (0,createClass/* default */.A)(Ft, [{
    key: "setWidth",
    value: function setWidth(t) {
      var e = t / this._width,
        i = e;
      this.scale(e, i);
    }
  }, {
    key: "setHeight",
    value: function setHeight(t) {
      var e = t / this._height,
        i = e;
      this.scale(e, i);
    }
  }, {
    key: "setPosition",
    value: function setPosition(t, e) {
      this.translate(t, e);
    }
  }, {
    key: "setCenterPosition",
    value: function setCenterPosition(t, e) {
      this.centerX(t), this.centerY(e);
    }
  }, {
    key: "top",
    value: function top(t) {
      this.setY(t);
    }
  }, {
    key: "bottom",
    value: function bottom(t) {
      var e = this._height * this.getScaleY();
      this.translateY(t - e);
    }
  }, {
    key: "left",
    value: function left(t) {
      this.setX(t);
    }
  }, {
    key: "right",
    value: function right(t) {
      var e = this._width * this.getScaleX();
      this.translateX(t - e);
    }
  }, {
    key: "centerX",
    value: function centerX(t) {
      var e = this._width * this.getScaleX();
      this.translateX(t - e / 2);
    }
  }, {
    key: "setX",
    value: function setX(t) {
      this.translateX(t);
    }
  }, {
    key: "centerY",
    value: function centerY(t) {
      var e = this._height * this.getScaleY();
      this.translateY(t - e / 2);
    }
  }, {
    key: "setY",
    value: function setY(t) {
      this.translateY(t);
    }
  }, {
    key: "setupFromLayout",
    value: function setupFromLayout(t) {
      for (var _e42 = t.begin(); _e42.notEqual(t.end()); _e42.preIncrement()) {
        var _t33 = _e42.ptr().first,
          _i26 = _e42.ptr().second;
        'width' == _t33 ? this.setWidth(_i26) : 'height' == _t33 && this.setHeight(_i26);
      }
      for (var _e43 = t.begin(); _e43.notEqual(t.end()); _e43.preIncrement()) {
        var _t34 = _e43.ptr().first,
          _i27 = _e43.ptr().second;
        'x' == _t34 ? this.setX(_i27) : 'y' == _t34 ? this.setY(_i27) : 'center_x' == _t34 ? this.centerX(_i27) : 'center_y' == _t34 ? this.centerY(_i27) : 'top' == _t34 ? this.top(_i27) : 'bottom' == _t34 ? this.bottom(_i27) : 'left' == _t34 ? this.left(_i27) : 'right' == _t34 && this.right(_i27);
      }
    }
  }]);
  return Ft;
}(c);
(Pt || (Pt = {})).CubismModelMatrix = Ft;
var It = /*#__PURE__*/function () {
  function It(t, e) {
    (0,classCallCheck/* default */.A)(this, It);
    this.x = t, this.y = e, this.x = null == t ? 0 : t, this.y = null == e ? 0 : e;
  }
  (0,createClass/* default */.A)(It, [{
    key: "add",
    value: function add(t) {
      var e = new It(0, 0);
      return e.x = this.x + t.x, e.y = this.y + t.y, e;
    }
  }, {
    key: "substract",
    value: function substract(t) {
      var e = new It(0, 0);
      return e.x = this.x - t.x, e.y = this.y - t.y, e;
    }
  }, {
    key: "multiply",
    value: function multiply(t) {
      var e = new It(0, 0);
      return e.x = this.x * t.x, e.y = this.y * t.y, e;
    }
  }, {
    key: "multiplyByScaler",
    value: function multiplyByScaler(t) {
      return this.multiply(new It(t, t));
    }
  }, {
    key: "division",
    value: function division(t) {
      var e = new It(0, 0);
      return e.x = this.x / t.x, e.y = this.y / t.y, e;
    }
  }, {
    key: "divisionByScalar",
    value: function divisionByScalar(t) {
      return this.division(new It(t, t));
    }
  }, {
    key: "getLength",
    value: function getLength() {
      return Math.sqrt(this.x * this.x + this.y * this.y);
    }
  }, {
    key: "getDistanceWith",
    value: function getDistanceWith(t) {
      return Math.sqrt((this.x - t.x) * (this.x - t.x) + (this.y - t.y) * (this.y - t.y));
    }
  }, {
    key: "dot",
    value: function dot(t) {
      return this.x * t.x + this.y * t.y;
    }
  }, {
    key: "normalize",
    value: function normalize() {
      var t = Math.pow(this.x * this.x + this.y * this.y, .5);
      this.x = this.x / t, this.y = this.y / t;
    }
  }, {
    key: "isEqual",
    value: function isEqual(t) {
      return this.x == t.x && this.y == t.y;
    }
  }, {
    key: "isNotEqual",
    value: function isNotEqual(t) {
      return !this.isEqual(t);
    }
  }]);
  return It;
}();
(Bt || (Bt = {})).CubismVector2 = It;
var Vt = /*#__PURE__*/function () {
  function Vt() {
    (0,classCallCheck/* default */.A)(this, Vt);
  }
  (0,createClass/* default */.A)(Vt, null, [{
    key: "range",
    value: function range(t, e, i) {
      return t < e ? t = e : t > i && (t = i), t;
    }
  }, {
    key: "sin",
    value: function sin(t) {
      return Math.sin(t);
    }
  }, {
    key: "cos",
    value: function cos(t) {
      return Math.cos(t);
    }
  }, {
    key: "abs",
    value: function abs(t) {
      return Math.abs(t);
    }
  }, {
    key: "sqrt",
    value: function sqrt(t) {
      return Math.sqrt(t);
    }
  }, {
    key: "cbrt",
    value: function cbrt(t) {
      if (0 === t) return t;
      var e = t;
      var i = e < 0;
      var s;
      return i && (e = -e), e === 1 / 0 ? s = 1 / 0 : (s = Math.exp(Math.log(e) / 3), s = (e / (s * s) + 2 * s) / 3), i ? -s : s;
    }
  }, {
    key: "getEasingSine",
    value: function getEasingSine(t) {
      return t < 0 ? 0 : t > 1 ? 1 : .5 - .5 * this.cos(t * Math.PI);
    }
  }, {
    key: "max",
    value: function max(t, e) {
      return t > e ? t : e;
    }
  }, {
    key: "min",
    value: function min(t, e) {
      return t > e ? e : t;
    }
  }, {
    key: "clamp",
    value: function clamp(t, e, i) {
      return t < e ? e : i < t ? i : t;
    }
  }, {
    key: "degreesToRadian",
    value: function degreesToRadian(t) {
      return t / 180 * Math.PI;
    }
  }, {
    key: "radianToDegrees",
    value: function radianToDegrees(t) {
      return 180 * t / Math.PI;
    }
  }, {
    key: "directionToRadian",
    value: function directionToRadian(t, e) {
      var i = Math.atan2(e.y, e.x) - Math.atan2(t.y, t.x);
      for (; i < -Math.PI;) i += 2 * Math.PI;
      for (; i > Math.PI;) i -= 2 * Math.PI;
      return i;
    }
  }, {
    key: "directionToDegrees",
    value: function directionToDegrees(t, e) {
      var i = this.directionToRadian(t, e);
      var s = this.radianToDegrees(i);
      return e.x - t.x > 0 && (s = -s), s;
    }
  }, {
    key: "radianToDirection",
    value: function radianToDirection(t) {
      var e = new It();
      return e.x = this.sin(t), e.y = this.cos(t), e;
    }
  }, {
    key: "quadraticEquation",
    value: function quadraticEquation(t, e, i) {
      return this.abs(t) < Vt.Epsilon ? this.abs(e) < Vt.Epsilon ? -i : -i / e : -(e + this.sqrt(e * e - 4 * t * i)) / (2 * t);
    }
  }, {
    key: "cardanoAlgorithmForBezier",
    value: function cardanoAlgorithmForBezier(t, e, i, s) {
      if (this.abs(t) < Vt.Epsilon) return this.range(this.quadraticEquation(e, i, s), 0, 1);
      var r = e / t,
        a = i / t,
        n = (3 * a - r * r) / 3,
        o = n / 3,
        l = (2 * r * r * r - 9 * r * a + 27 * (s / t)) / 27,
        h = l / 2,
        u = h * h + o * o * o,
        g = .5,
        d = .51;
      if (u < 0) {
        var _t35 = -n / 3,
          _e44 = _t35 * _t35 * _t35,
          _i28 = this.sqrt(_e44),
          _s25 = -l / (2 * _i28),
          _a4 = this.range(_s25, -1, 1),
          _o = Math.acos(_a4),
          _h = 2 * this.cbrt(_i28),
          _u = _h * this.cos(_o / 3) - r / 3;
        if (this.abs(_u - g) < d) return this.range(_u, 0, 1);
        var _2 = _h * this.cos((_o + 2 * Math.PI) / 3) - r / 3;
        if (this.abs(_2 - g) < d) return this.range(_2, 0, 1);
        var _c2 = _h * this.cos((_o + 4 * Math.PI) / 3) - r / 3;
        return this.range(_c2, 0, 1);
      }
      if (0 == u) {
        var _t36;
        _t36 = h < 0 ? this.cbrt(-h) : -this.cbrt(h);
        var _e45 = 2 * _t36 - r / 3;
        if (this.abs(_e45 - g) < d) return this.range(_e45, 0, 1);
        var _i29 = -_t36 - r / 3;
        return this.range(_i29, 0, 1);
      }
      var _ = this.sqrt(u),
        c = this.cbrt(_ - h) - this.cbrt(_ + h) - r / 3;
      return this.range(c, 0, 1);
    }
  }, {
    key: "mod",
    value: function mod(t, e) {
      if (!isFinite(t) || 0 === e || isNaN(t) || isNaN(e)) return console.warn("divided: ".concat(t, ", divisor: ").concat(e, " mod() returns 'NaN'.")), NaN;
      var i = Math.abs(t),
        s = Math.abs(e);
      var r = i - Math.floor(i / s) * s;
      return r *= Math.sign(t), r;
    }
  }]);
  return Vt;
}();
Vt.Epsilon = 1e-5, (wt || (wt = {})).CubismMath = Vt;
var Et = /*#__PURE__*/function () {
  function Et() {
    (0,classCallCheck/* default */.A)(this, Et);
    this._faceTargetX = 0, this._faceTargetY = 0, this._faceX = 0, this._faceY = 0, this._faceVX = 0, this._faceVY = 0, this._lastTimeSeconds = 0, this._userTimeSeconds = 0;
  }
  (0,createClass/* default */.A)(Et, [{
    key: "update",
    value: function update(t) {
      this._userTimeSeconds += t;
      var e = 4 / 30;
      if (0 == this._lastTimeSeconds) return void (this._lastTimeSeconds = this._userTimeSeconds);
      var i = 30 * (this._userTimeSeconds - this._lastTimeSeconds);
      this._lastTimeSeconds = this._userTimeSeconds;
      var s = i * e / 4.5,
        r = this._faceTargetX - this._faceX,
        a = this._faceTargetY - this._faceY;
      if (Vt.abs(r) <= .01 && Vt.abs(a) <= .01) return;
      var n = Vt.sqrt(r * r + a * a),
        o = e * a / n;
      var l = e * r / n - this._faceVX,
        h = o - this._faceVY;
      var u = Vt.sqrt(l * l + h * h);
      (u < -s || u > s) && (l *= s / u, h *= s / u), this._faceVX += l, this._faceVY += h;
      {
        var _t37 = .5 * (Vt.sqrt(s * s + 16 * s * n - 8 * s * n) - s),
          _e46 = Vt.sqrt(this._faceVX * this._faceVX + this._faceVY * this._faceVY);
        _e46 > _t37 && (this._faceVX *= _t37 / _e46, this._faceVY *= _t37 / _e46);
      }
      this._faceX += this._faceVX, this._faceY += this._faceVY;
    }
  }, {
    key: "getX",
    value: function getX() {
      return this._faceX;
    }
  }, {
    key: "getY",
    value: function getY() {
      return this._faceY;
    }
  }, {
    key: "set",
    value: function set(t, e) {
      this._faceTargetX = t, this._faceTargetY = e;
    }
  }]);
  return Et;
}();
var Rt, Tt;
(Rt || (Rt = {})).CubismTargetPoint = Et;
var Lt = /*#__PURE__*/function () {
  function Lt() {
    var _this11 = this;
    (0,classCallCheck/* default */.A)(this, Lt);
    this.setBeganMotionHandler = function (t) {
      return _this11._onBeganMotion = t;
    }, this.getBeganMotionHandler = function () {
      return _this11._onBeganMotion;
    }, this.setFinishedMotionHandler = function (t) {
      return _this11._onFinishedMotion = t;
    }, this.getFinishedMotionHandler = function () {
      return _this11._onFinishedMotion;
    }, this._fadeInSeconds = -1, this._fadeOutSeconds = -1, this._weight = 1, this._offsetSeconds = 0, this._isLoop = !1, this._isLoopFadeIn = !0, this._previousLoopState = this._isLoop, this._firedEventValues = new e();
  }
  (0,createClass/* default */.A)(Lt, [{
    key: "release",
    value: function release() {
      this._weight = 0;
    }
  }, {
    key: "updateParameters",
    value: function updateParameters(t, e, i) {
      if (!e.isAvailable() || e.isFinished()) return;
      this.setupMotionQueueEntry(e, i);
      var s = this.updateFadeWeight(e, i);
      this.doUpdateParameters(t, i, s, e), e.getEndTime() > 0 && e.getEndTime() < i && e.setIsFinished(!0);
    }
  }, {
    key: "setupMotionQueueEntry",
    value: function setupMotionQueueEntry(t, e) {
      null == t || t.isStarted() || t.isAvailable() && (t.setIsStarted(!0), t.setStartTime(e - this._offsetSeconds), t.setFadeInStartTime(e), t.getEndTime() < 0 && this.adjustEndTime(t), t._motion._onBeganMotion && t._motion._onBeganMotion(t._motion));
    }
  }, {
    key: "updateFadeWeight",
    value: function updateFadeWeight(t, e) {
      null == t && P.print(K.LogLevel_Error, 'motionQueueEntry is null.');
      var i = this._weight;
      return i = i * (0 == this._fadeInSeconds ? 1 : Vt.getEasingSine((e - t.getFadeInStartTime()) / this._fadeInSeconds)) * (0 == this._fadeOutSeconds || t.getEndTime() < 0 ? 1 : Vt.getEasingSine((t.getEndTime() - e) / this._fadeOutSeconds)), t.setState(e, i), C(0 <= i && i <= 1), i;
    }
  }, {
    key: "setFadeInTime",
    value: function setFadeInTime(t) {
      this._fadeInSeconds = t;
    }
  }, {
    key: "setFadeOutTime",
    value: function setFadeOutTime(t) {
      this._fadeOutSeconds = t;
    }
  }, {
    key: "getFadeOutTime",
    value: function getFadeOutTime() {
      return this._fadeOutSeconds;
    }
  }, {
    key: "getFadeInTime",
    value: function getFadeInTime() {
      return this._fadeInSeconds;
    }
  }, {
    key: "setWeight",
    value: function setWeight(t) {
      this._weight = t;
    }
  }, {
    key: "getWeight",
    value: function getWeight() {
      return this._weight;
    }
  }, {
    key: "getDuration",
    value: function getDuration() {
      return -1;
    }
  }, {
    key: "getLoopDuration",
    value: function getLoopDuration() {
      return -1;
    }
  }, {
    key: "setOffsetTime",
    value: function setOffsetTime(t) {
      this._offsetSeconds = t;
    }
  }, {
    key: "setLoop",
    value: function setLoop(t) {
      this._isLoop = t;
    }
  }, {
    key: "getLoop",
    value: function getLoop() {
      return this._isLoop;
    }
  }, {
    key: "setLoopFadeIn",
    value: function setLoopFadeIn(t) {
      this._isLoopFadeIn = t;
    }
  }, {
    key: "getLoopFadeIn",
    value: function getLoopFadeIn() {
      return this._isLoopFadeIn;
    }
  }, {
    key: "getFiredEvent",
    value: function getFiredEvent(t, e) {
      return this._firedEventValues;
    }
  }, {
    key: "isExistModelOpacity",
    value: function isExistModelOpacity() {
      return !1;
    }
  }, {
    key: "getModelOpacityIndex",
    value: function getModelOpacityIndex() {
      return -1;
    }
  }, {
    key: "getModelOpacityId",
    value: function getModelOpacityId(t) {
      return null;
    }
  }, {
    key: "getModelOpacityValue",
    value: function getModelOpacityValue() {
      return 1;
    }
  }, {
    key: "adjustEndTime",
    value: function adjustEndTime(t) {
      var e = this.getDuration(),
        i = e <= 0 ? -1 : t.getStartTime() + e;
      t.setEndTime(i);
    }
  }], [{
    key: "delete",
    value: function _delete(t) {
      t.release(), t = null;
    }
  }]);
  return Lt;
}();
(Tt || (Tt = {})).ACubismMotion = Lt;
var Dt = 'Parameters',
  At = 'Blend';
var Ot = /*#__PURE__*/function (_Lt) {
  (0,inherits/* default */.A)(Ot, _Lt);
  function Ot() {
    var _this12;
    (0,classCallCheck/* default */.A)(this, Ot);
    _this12 = (0,callSuper/* default */.A)(this, Ot), _this12._parameters = new e(), _this12._fadeWeight = 0;
    return _this12;
  }
  (0,createClass/* default */.A)(Ot, [{
    key: "doUpdateParameters",
    value: function doUpdateParameters(t, e, i, s) {
      for (var _e47 = 0; _e47 < this._parameters.getSize(); ++_e47) {
        var _s26 = this._parameters.at(_e47);
        switch (_s26.blendType) {
          case kt.Additive:
            t.addParameterValueById(_s26.parameterId, _s26.value, i);
            break;
          case kt.Multiply:
            t.multiplyParameterValueById(_s26.parameterId, _s26.value, i);
            break;
          case kt.Overwrite:
            t.setParameterValueById(_s26.parameterId, _s26.value, i);
        }
      }
    }
  }, {
    key: "calculateExpressionParameters",
    value: function calculateExpressionParameters(t, e, i, s, r, a) {
      if (null != i && null != s && i.isAvailable()) {
        this._fadeWeight = this.updateFadeWeight(i, e);
        for (var _e48 = 0; _e48 < s.getSize(); ++_e48) {
          var _i30 = s.at(_e48);
          if (null == _i30.parameterId) continue;
          var _n3 = _i30.overwriteValue = t.getParameterValueById(_i30.parameterId),
            _o2 = this.getExpressionParameters();
          var _l = -1;
          for (var _t38 = 0; _t38 < _o2.getSize(); ++_t38) {
            if (_i30.parameterId == _o2.at(_t38).parameterId) {
              _l = _t38;
              break;
            }
          }
          if (_l < 0) {
            0 == r ? (_i30.additiveValue = Ot.DefaultAdditiveValue, _i30.multiplyValue = Ot.DefaultMultiplyValue, _i30.overwriteValue = _n3) : (_i30.additiveValue = this.calculateValue(_i30.additiveValue, Ot.DefaultAdditiveValue, a), _i30.multiplyValue = this.calculateValue(_i30.multiplyValue, Ot.DefaultMultiplyValue, a), _i30.overwriteValue = this.calculateValue(_i30.overwriteValue, _n3, a));
            continue;
          }
          var _h2 = _o2.at(_l).value;
          var _u2 = void 0,
            _g = void 0,
            _d = void 0;
          switch (_o2.at(_l).blendType) {
            case kt.Additive:
              _u2 = _h2, _g = Ot.DefaultMultiplyValue, _d = _n3;
              break;
            case kt.Multiply:
              _u2 = Ot.DefaultAdditiveValue, _g = _h2, _d = _n3;
              break;
            case kt.Overwrite:
              _u2 = Ot.DefaultAdditiveValue, _g = Ot.DefaultMultiplyValue, _d = _h2;
              break;
            default:
              return;
          }
          0 == r ? (_i30.additiveValue = _u2, _i30.multiplyValue = _g, _i30.overwriteValue = _d) : (_i30.additiveValue = _i30.additiveValue * (1 - a) + _u2 * a, _i30.multiplyValue = _i30.multiplyValue * (1 - a) + _g * a, _i30.overwriteValue = _i30.overwriteValue * (1 - a) + _d * a);
        }
      }
    }
  }, {
    key: "getExpressionParameters",
    value: function getExpressionParameters() {
      return this._parameters;
    }
  }, {
    key: "getFadeWeight",
    value: function getFadeWeight() {
      return this._fadeWeight;
    }
  }, {
    key: "parse",
    value: function parse(t, e) {
      var i = L.create(t, e);
      if (!i) return;
      var s = i.getRoot();
      this.setFadeInTime(s.getValueByString('FadeInTime').toFloat(1)), this.setFadeOutTime(s.getValueByString('FadeOutTime').toFloat(1));
      var r = s.getValueByString(Dt).getSize();
      this._parameters.prepareCapacity(r);
      for (var _t39 = 0; _t39 < r; ++_t39) {
        var _e49 = s.getValueByString(Dt).getValueByIndex(_t39),
          _i31 = $.getIdManager().getId(_e49.getValueByString('Id').getRawString()),
          _r7 = _e49.getValueByString('Value').toFloat();
        var _a5 = void 0;
        _a5 = _e49.getValueByString(At).isNull() || 'Add' == _e49.getValueByString(At).getString() ? kt.Additive : 'Multiply' == _e49.getValueByString(At).getString() ? kt.Multiply : 'Overwrite' == _e49.getValueByString(At).getString() ? kt.Overwrite : kt.Additive;
        var _n4 = new Ut();
        _n4.parameterId = _i31, _n4.blendType = _a5, _n4.value = _r7, this._parameters.pushBack(_n4);
      }
      L.delete(i);
    }
  }, {
    key: "calculateValue",
    value: function calculateValue(t, e, i) {
      return t * (1 - i) + e * i;
    }
  }], [{
    key: "create",
    value: function create(t, e) {
      var i = new Ot();
      return i.parse(t, e), i;
    }
  }]);
  return Ot;
}(Lt);
var kt, Nt, zt;
Ot.DefaultAdditiveValue = 0, Ot.DefaultMultiplyValue = 1, function (t) {
  t[t.Additive = 0] = 'Additive', t[t.Multiply = 1] = 'Multiply', t[t.Overwrite = 2] = 'Overwrite';
}(kt || (kt = {}));
var Ut = /*#__PURE__*/(0,createClass/* default */.A)(function Ut() {
  (0,classCallCheck/* default */.A)(this, Ut);
});
!function (t) {
  t.CubismExpressionMotion = Ot, t.ExpressionBlendType = kt, t.ExpressionParameter = Ut;
}(Nt || (Nt = {}));
var Gt = /*#__PURE__*/function () {
  function Gt() {
    (0,classCallCheck/* default */.A)(this, Gt);
    this._autoDelete = !1, this._motion = null, this._available = !0, this._finished = !1, this._started = !1, this._startTimeSeconds = -1, this._fadeInStartTimeSeconds = 0, this._endTimeSeconds = -1, this._stateTimeSeconds = 0, this._stateWeight = 0, this._lastEventCheckSeconds = 0, this._motionQueueEntryHandle = this, this._fadeOutSeconds = 0, this._isTriggeredFadeOut = !1;
  }
  (0,createClass/* default */.A)(Gt, [{
    key: "release",
    value: function release() {
      this._autoDelete && this._motion && Lt.delete(this._motion);
    }
  }, {
    key: "setFadeOut",
    value: function setFadeOut(t) {
      this._fadeOutSeconds = t, this._isTriggeredFadeOut = !0;
    }
  }, {
    key: "startFadeOut",
    value: function startFadeOut(t, e) {
      var i = e + t;
      this._isTriggeredFadeOut = !0, (this._endTimeSeconds < 0 || i < this._endTimeSeconds) && (this._endTimeSeconds = i);
    }
  }, {
    key: "isFinished",
    value: function isFinished() {
      return this._finished;
    }
  }, {
    key: "isStarted",
    value: function isStarted() {
      return this._started;
    }
  }, {
    key: "getStartTime",
    value: function getStartTime() {
      return this._startTimeSeconds;
    }
  }, {
    key: "getFadeInStartTime",
    value: function getFadeInStartTime() {
      return this._fadeInStartTimeSeconds;
    }
  }, {
    key: "getEndTime",
    value: function getEndTime() {
      return this._endTimeSeconds;
    }
  }, {
    key: "setStartTime",
    value: function setStartTime(t) {
      this._startTimeSeconds = t;
    }
  }, {
    key: "setFadeInStartTime",
    value: function setFadeInStartTime(t) {
      this._fadeInStartTimeSeconds = t;
    }
  }, {
    key: "setEndTime",
    value: function setEndTime(t) {
      this._endTimeSeconds = t;
    }
  }, {
    key: "setIsFinished",
    value: function setIsFinished(t) {
      this._finished = t;
    }
  }, {
    key: "setIsStarted",
    value: function setIsStarted(t) {
      this._started = t;
    }
  }, {
    key: "isAvailable",
    value: function isAvailable() {
      return this._available;
    }
  }, {
    key: "setIsAvailable",
    value: function setIsAvailable(t) {
      this._available = t;
    }
  }, {
    key: "setState",
    value: function setState(t, e) {
      this._stateTimeSeconds = t, this._stateWeight = e;
    }
  }, {
    key: "getStateTime",
    value: function getStateTime() {
      return this._stateTimeSeconds;
    }
  }, {
    key: "getStateWeight",
    value: function getStateWeight() {
      return this._stateWeight;
    }
  }, {
    key: "getLastCheckEventSeconds",
    value: function getLastCheckEventSeconds() {
      return this._lastEventCheckSeconds;
    }
  }, {
    key: "setLastCheckEventSeconds",
    value: function setLastCheckEventSeconds(t) {
      this._lastEventCheckSeconds = t;
    }
  }, {
    key: "isTriggeredFadeOut",
    value: function isTriggeredFadeOut() {
      return this._isTriggeredFadeOut;
    }
  }, {
    key: "getFadeOutSeconds",
    value: function getFadeOutSeconds() {
      return this._fadeOutSeconds;
    }
  }, {
    key: "getCubismMotion",
    value: function getCubismMotion() {
      return this._motion;
    }
  }]);
  return Gt;
}();
(zt || (zt = {})).CubismMotionQueueEntry = Gt;
var Xt = /*#__PURE__*/function () {
  function Xt() {
    (0,classCallCheck/* default */.A)(this, Xt);
    this._userTimeSeconds = 0, this._eventCallBack = null, this._eventCustomData = null, this._motions = new e();
  }
  (0,createClass/* default */.A)(Xt, [{
    key: "release",
    value: function release() {
      for (var _t40 = 0; _t40 < this._motions.getSize(); ++_t40) this._motions.at(_t40) && (this._motions.at(_t40).release(), this._motions.set(_t40, null));
      this._motions = null;
    }
  }, {
    key: "startMotion",
    value: function startMotion(t, e, i) {
      if (null == t) return Yt;
      var s = null;
      for (var _t41 = 0; _t41 < this._motions.getSize(); ++_t41) s = this._motions.at(_t41), null != s && s.setFadeOut(s._motion.getFadeOutTime());
      return s = new Gt(), s._autoDelete = e, s._motion = t, this._motions.pushBack(s), s._motionQueueEntryHandle;
    }
  }, {
    key: "isFinished",
    value: function isFinished() {
      for (var _t42 = this._motions.begin(); _t42.notEqual(this._motions.end());) {
        var _e50 = _t42.ptr();
        if (null == _e50) {
          _t42 = this._motions.erase(_t42);
          continue;
        }
        if (null != _e50._motion) {
          if (!_e50.isFinished()) return !1;
          _t42.preIncrement();
        } else {
          _e50.release(), _e50 = null, _t42 = this._motions.erase(_t42);
        }
      }
      return !0;
    }
  }, {
    key: "isFinishedByHandle",
    value: function isFinishedByHandle(t) {
      for (var _e51 = this._motions.begin(); _e51.notEqual(this._motions.end()); _e51.increment()) {
        var _i32 = _e51.ptr();
        if (null != _i32 && _i32._motionQueueEntryHandle == t && !_i32.isFinished()) return !1;
      }
      return !0;
    }
  }, {
    key: "stopAllMotions",
    value: function stopAllMotions() {
      for (var _t43 = this._motions.begin(); _t43.notEqual(this._motions.end());) {
        var _e52 = _t43.ptr();
        null != _e52 ? (_e52.release(), _e52 = null, _t43 = this._motions.erase(_t43)) : _t43 = this._motions.erase(_t43);
      }
    }
  }, {
    key: "getCubismMotionQueueEntries",
    value: function getCubismMotionQueueEntries() {
      return this._motions;
    }
  }, {
    key: "getCubismMotionQueueEntry",
    value: function getCubismMotionQueueEntry(t) {
      for (var _e53 = this._motions.begin(); _e53.notEqual(this._motions.end()); _e53.preIncrement()) {
        var _i33 = _e53.ptr();
        if (null != _i33 && _i33._motionQueueEntryHandle == t) return _i33;
      }
      return null;
    }
  }, {
    key: "setEventCallback",
    value: function setEventCallback(t) {
      var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
      this._eventCallBack = t, this._eventCustomData = e;
    }
  }, {
    key: "doUpdateMotion",
    value: function doUpdateMotion(t, e) {
      var i = !1;
      for (var _s27 = this._motions.begin(); _s27.notEqual(this._motions.end());) {
        var _r8 = _s27.ptr();
        if (null == _r8) {
          _s27 = this._motions.erase(_s27);
          continue;
        }
        var _a6 = _r8._motion;
        if (null == _a6) {
          _r8.release(), _r8 = null, _s27 = this._motions.erase(_s27);
          continue;
        }
        _a6.updateParameters(t, _r8, e), i = !0;
        var _n5 = _a6.getFiredEvent(_r8.getLastCheckEventSeconds() - _r8.getStartTime(), e - _r8.getStartTime());
        for (var _t44 = 0; _t44 < _n5.getSize(); ++_t44) this._eventCallBack(this, _n5.at(_t44), this._eventCustomData);
        _r8.setLastCheckEventSeconds(e), _r8.isFinished() ? (_r8.release(), _r8 = null, _s27 = this._motions.erase(_s27)) : (_r8.isTriggeredFadeOut() && _r8.startFadeOut(_r8.getFadeOutSeconds(), e), _s27.preIncrement());
      }
      return i;
    }
  }]);
  return Xt;
}();
var Yt = -1;
var jt, Ht, qt, Wt, Jt;
!function (t) {
  t.CubismMotionQueueManager = Xt, t.InvalidMotionQueueEntryHandleValue = Yt;
}(jt || (jt = {}));
var $t = /*#__PURE__*/(0,createClass/* default */.A)(function $t() {
  (0,classCallCheck/* default */.A)(this, $t);
});
var Zt = /*#__PURE__*/function (_Xt) {
  (0,inherits/* default */.A)(Zt, _Xt);
  function Zt() {
    var _this13;
    (0,classCallCheck/* default */.A)(this, Zt);
    _this13 = (0,callSuper/* default */.A)(this, Zt), _this13._currentPriority = 0, _this13._reservePriority = 0, _this13._expressionParameterValues = new e(), _this13._fadeWeights = new e();
    return _this13;
  }
  (0,createClass/* default */.A)(Zt, [{
    key: "release",
    value: function release() {
      this._expressionParameterValues && (J(this._expressionParameterValues), this._expressionParameterValues = null), this._fadeWeights && (J(this._fadeWeights), this._fadeWeights = null);
    }
  }, {
    key: "getCurrentPriority",
    value: function getCurrentPriority() {
      return M('CubismExpressionMotionManager.getCurrentPriority() is deprecated because a priority value is not actually used during expression motion playback.'), this._currentPriority;
    }
  }, {
    key: "getReservePriority",
    value: function getReservePriority() {
      return M('CubismExpressionMotionManager.getReservePriority() is deprecated because a priority value is not actually used during expression motion playback.'), this._reservePriority;
    }
  }, {
    key: "getFadeWeight",
    value: function getFadeWeight(t) {
      return t < 0 || this._fadeWeights.getSize() < 1 || t >= this._fadeWeights.getSize() ? (console.warn('Failed to get the fade weight value. The element at that index does not exist.'), -1) : this._fadeWeights.at(t);
    }
  }, {
    key: "setFadeWeight",
    value: function setFadeWeight(t, e) {
      t < 0 || this._fadeWeights.getSize() < 1 || this._fadeWeights.getSize() <= t ? console.warn('Failed to set the fade weight value. The element at that index does not exist.') : this._fadeWeights.set(t, e);
    }
  }, {
    key: "setReservePriority",
    value: function setReservePriority(t) {
      M('CubismExpressionMotionManager.setReservePriority() is deprecated because a priority value is not actually used during expression motion playback.'), this._reservePriority = t;
    }
  }, {
    key: "startMotionPriority",
    value: function startMotionPriority(t, e, i) {
      return M('CubismExpressionMotionManager.startMotionPriority() is deprecated because a priority value is not actually used during expression motion playback.'), i == this.getReservePriority() && this.setReservePriority(0), this._currentPriority = i, this.startMotion(t, e);
    }
  }, {
    key: "updateMotion",
    value: function updateMotion(t, e) {
      this._userTimeSeconds += e;
      var i = !1;
      var s = this.getCubismMotionQueueEntries();
      var r = 0,
        a = 0;
      if (this._fadeWeights.getSize() !== s.getSize()) {
        var _t45 = s.getSize() - this._fadeWeights.getSize();
        for (var _e54 = 0; _e54 < _t45; _e54++) this._fadeWeights.pushBack(0);
      }
      for (var _e55 = this._motions.begin(); _e55.notEqual(this._motions.end());) {
        var _n6 = _e55.ptr();
        if (null == _n6) {
          _e55 = s.erase(_e55);
          continue;
        }
        var _o3 = _n6.getCubismMotion();
        if (null == _o3) {
          J(_n6), _e55 = s.erase(_e55);
          continue;
        }
        var _l2 = _o3.getExpressionParameters();
        if (_n6.isAvailable()) {
          for (var _e56 = 0; _e56 < _l2.getSize(); ++_e56) {
            if (null == _l2.at(_e56).parameterId) continue;
            var _i34 = -1;
            for (var _t46 = 0; _t46 < this._expressionParameterValues.getSize(); ++_t46) {
              if (this._expressionParameterValues.at(_t46).parameterId == _l2.at(_e56).parameterId) {
                _i34 = _t46;
                break;
              }
            }
            if (_i34 >= 0) continue;
            var _s28 = new $t();
            _s28.parameterId = _l2.at(_e56).parameterId, _s28.additiveValue = Ot.DefaultAdditiveValue, _s28.multiplyValue = Ot.DefaultMultiplyValue, _s28.overwriteValue = t.getParameterValueById(_s28.parameterId), this._expressionParameterValues.pushBack(_s28);
          }
        }
        _o3.setupMotionQueueEntry(_n6, this._userTimeSeconds), this.setFadeWeight(a, _o3.updateFadeWeight(_n6, this._userTimeSeconds)), _o3.calculateExpressionParameters(t, this._userTimeSeconds, _n6, this._expressionParameterValues, a, this.getFadeWeight(a)), r += 0 == _o3.getFadeInTime() ? 1 : Vt.getEasingSine((this._userTimeSeconds - _n6.getFadeInStartTime()) / _o3.getFadeInTime()), i = !0, _n6.isTriggeredFadeOut() && _n6.startFadeOut(_n6.getFadeOutSeconds(), this._userTimeSeconds), _e55.preIncrement(), ++a;
      }
      if (s.getSize() > 1) {
        if (this.getFadeWeight(this._fadeWeights.getSize() - 1) >= 1) {
          for (var _t47 = s.getSize() - 2; _t47 >= 0; --_t47) {
            J(s.at(_t47)), s.remove(_t47), this._fadeWeights.remove(_t47);
          }
        }
      }
      r > 1 && (r = 1);
      for (var _e57 = 0; _e57 < this._expressionParameterValues.getSize(); ++_e57) {
        var _i35 = this._expressionParameterValues.at(_e57);
        t.setParameterValueById(_i35.parameterId, (_i35.overwriteValue + _i35.additiveValue) * _i35.multiplyValue, r), _i35.additiveValue = Ot.DefaultAdditiveValue, _i35.multiplyValue = Ot.DefaultMultiplyValue;
      }
      return i;
    }
  }]);
  return Zt;
}(Xt);
(Ht || (Ht = {})).CubismExpressionMotionManager = Zt, function (t) {
  t[t.CubismMotionCurveTarget_Model = 0] = 'CubismMotionCurveTarget_Model', t[t.CubismMotionCurveTarget_Parameter = 1] = 'CubismMotionCurveTarget_Parameter', t[t.CubismMotionCurveTarget_PartOpacity = 2] = 'CubismMotionCurveTarget_PartOpacity';
}(qt || (qt = {})), function (t) {
  t[t.CubismMotionSegmentType_Linear = 0] = 'CubismMotionSegmentType_Linear', t[t.CubismMotionSegmentType_Bezier = 1] = 'CubismMotionSegmentType_Bezier', t[t.CubismMotionSegmentType_Stepped = 2] = 'CubismMotionSegmentType_Stepped', t[t.CubismMotionSegmentType_InverseStepped = 3] = 'CubismMotionSegmentType_InverseStepped';
}(Wt || (Wt = {}));
var Kt = /*#__PURE__*/(0,createClass/* default */.A)(function Kt() {
  (0,classCallCheck/* default */.A)(this, Kt);
  this.time = 0, this.value = 0;
});
var Qt = /*#__PURE__*/(0,createClass/* default */.A)(function Qt() {
  (0,classCallCheck/* default */.A)(this, Qt);
  this.evaluate = null, this.basePointIndex = 0, this.segmentType = 0;
});
var te = /*#__PURE__*/(0,createClass/* default */.A)(function te() {
  (0,classCallCheck/* default */.A)(this, te);
  this.type = qt.CubismMotionCurveTarget_Model, this.segmentCount = 0, this.baseSegmentIndex = 0, this.fadeInTime = 0, this.fadeOutTime = 0;
});
var ee = /*#__PURE__*/(0,createClass/* default */.A)(function ee() {
  (0,classCallCheck/* default */.A)(this, ee);
  this.fireTime = 0;
});
var ie = /*#__PURE__*/(0,createClass/* default */.A)(function ie() {
  (0,classCallCheck/* default */.A)(this, ie);
  this.duration = 0, this.loop = !1, this.curveCount = 0, this.eventCount = 0, this.fps = 0, this.curves = new e(), this.segments = new e(), this.points = new e(), this.events = new e();
});
!function (t) {
  t.CubismMotionCurve = te, t.CubismMotionCurveTarget = qt, t.CubismMotionData = ie, t.CubismMotionEvent = ee, t.CubismMotionPoint = Kt, t.CubismMotionSegment = Qt, t.CubismMotionSegmentType = Wt;
}(Jt || (Jt = {}));
var se = 'Meta',
  re = 'Curves',
  ae = 'FadeInTime',
  ne = 'FadeOutTime',
  oe = 'Segments',
  le = 'UserData';
var he = /*#__PURE__*/function () {
  function he(t, e) {
    (0,classCallCheck/* default */.A)(this, he);
    this._json = L.create(t, e);
  }
  (0,createClass/* default */.A)(he, [{
    key: "release",
    value: function release() {
      L.delete(this._json);
    }
  }, {
    key: "getMotionDuration",
    value: function getMotionDuration() {
      return this._json.getRoot().getValueByString(se).getValueByString('Duration').toFloat();
    }
  }, {
    key: "isMotionLoop",
    value: function isMotionLoop() {
      return this._json.getRoot().getValueByString(se).getValueByString('Loop').toBoolean();
    }
  }, {
    key: "hasConsistency",
    value: function hasConsistency() {
      var t = !0;
      if (!this._json || !this._json.getRoot()) return !1;
      var e = this._json.getRoot().getValueByString(re).getVector().getSize();
      var i = 0,
        s = 0;
      for (var _t48 = 0; _t48 < e; ++_t48) {
        for (var _e58 = 0; _e58 < this.getMotionCurveSegmentCount(_t48);) {
          0 == _e58 && (s += 1, _e58 += 2);
          switch (this.getMotionCurveSegment(_t48, _e58)) {
            case Wt.CubismMotionSegmentType_Linear:
              s += 1, _e58 += 3;
              break;
            case Wt.CubismMotionSegmentType_Bezier:
              s += 3, _e58 += 7;
              break;
            case Wt.CubismMotionSegmentType_Stepped:
            case Wt.CubismMotionSegmentType_InverseStepped:
              s += 1, _e58 += 3;
              break;
            default:
              C(0);
          }
          ++i;
        }
      }
      return e != this.getMotionCurveCount() && (v('The number of curves does not match the metadata.'), t = !1), i != this.getMotionTotalSegmentCount() && (v('The number of segment does not match the metadata.'), t = !1), s != this.getMotionTotalPointCount() && (v('The number of point does not match the metadata.'), t = !1), t;
    }
  }, {
    key: "getEvaluationOptionFlag",
    value: function getEvaluationOptionFlag(t) {
      return ue.EvaluationOptionFlag_AreBeziersRistricted == t && this._json.getRoot().getValueByString(se).getValueByString('AreBeziersRestricted').toBoolean();
    }
  }, {
    key: "getMotionCurveCount",
    value: function getMotionCurveCount() {
      return this._json.getRoot().getValueByString(se).getValueByString('CurveCount').toInt();
    }
  }, {
    key: "getMotionFps",
    value: function getMotionFps() {
      return this._json.getRoot().getValueByString(se).getValueByString('Fps').toFloat();
    }
  }, {
    key: "getMotionTotalSegmentCount",
    value: function getMotionTotalSegmentCount() {
      return this._json.getRoot().getValueByString(se).getValueByString('TotalSegmentCount').toInt();
    }
  }, {
    key: "getMotionTotalPointCount",
    value: function getMotionTotalPointCount() {
      return this._json.getRoot().getValueByString(se).getValueByString('TotalPointCount').toInt();
    }
  }, {
    key: "isExistMotionFadeInTime",
    value: function isExistMotionFadeInTime() {
      return !this._json.getRoot().getValueByString(se).getValueByString(ae).isNull();
    }
  }, {
    key: "isExistMotionFadeOutTime",
    value: function isExistMotionFadeOutTime() {
      return !this._json.getRoot().getValueByString(se).getValueByString(ne).isNull();
    }
  }, {
    key: "getMotionFadeInTime",
    value: function getMotionFadeInTime() {
      return this._json.getRoot().getValueByString(se).getValueByString(ae).toFloat();
    }
  }, {
    key: "getMotionFadeOutTime",
    value: function getMotionFadeOutTime() {
      return this._json.getRoot().getValueByString(se).getValueByString(ne).toFloat();
    }
  }, {
    key: "getMotionCurveTarget",
    value: function getMotionCurveTarget(t) {
      return this._json.getRoot().getValueByString(re).getValueByIndex(t).getValueByString('Target').getRawString();
    }
  }, {
    key: "getMotionCurveId",
    value: function getMotionCurveId(t) {
      return $.getIdManager().getId(this._json.getRoot().getValueByString(re).getValueByIndex(t).getValueByString('Id').getRawString());
    }
  }, {
    key: "isExistMotionCurveFadeInTime",
    value: function isExistMotionCurveFadeInTime(t) {
      return !this._json.getRoot().getValueByString(re).getValueByIndex(t).getValueByString(ae).isNull();
    }
  }, {
    key: "isExistMotionCurveFadeOutTime",
    value: function isExistMotionCurveFadeOutTime(t) {
      return !this._json.getRoot().getValueByString(re).getValueByIndex(t).getValueByString(ne).isNull();
    }
  }, {
    key: "getMotionCurveFadeInTime",
    value: function getMotionCurveFadeInTime(t) {
      return this._json.getRoot().getValueByString(re).getValueByIndex(t).getValueByString(ae).toFloat();
    }
  }, {
    key: "getMotionCurveFadeOutTime",
    value: function getMotionCurveFadeOutTime(t) {
      return this._json.getRoot().getValueByString(re).getValueByIndex(t).getValueByString(ne).toFloat();
    }
  }, {
    key: "getMotionCurveSegmentCount",
    value: function getMotionCurveSegmentCount(t) {
      return this._json.getRoot().getValueByString(re).getValueByIndex(t).getValueByString(oe).getVector().getSize();
    }
  }, {
    key: "getMotionCurveSegment",
    value: function getMotionCurveSegment(t, e) {
      return this._json.getRoot().getValueByString(re).getValueByIndex(t).getValueByString(oe).getValueByIndex(e).toFloat();
    }
  }, {
    key: "getEventCount",
    value: function getEventCount() {
      return this._json.getRoot().getValueByString(se).getValueByString('UserDataCount').toInt();
    }
  }, {
    key: "getTotalEventValueSize",
    value: function getTotalEventValueSize() {
      return this._json.getRoot().getValueByString(se).getValueByString('TotalUserDataSize').toInt();
    }
  }, {
    key: "getEventTime",
    value: function getEventTime(t) {
      return this._json.getRoot().getValueByString(le).getValueByIndex(t).getValueByString('Time').toFloat();
    }
  }, {
    key: "getEventValue",
    value: function getEventValue(t) {
      return new g(this._json.getRoot().getValueByString(le).getValueByIndex(t).getValueByString('Value').getRawString());
    }
  }]);
  return he;
}();
var ue, ge;
!function (t) {
  t[t.EvaluationOptionFlag_AreBeziersRistricted = 0] = 'EvaluationOptionFlag_AreBeziersRistricted';
}(ue || (ue = {})), (ge || (ge = {})).CubismMotionJson = he;
var de = 'Opacity';
function _e(t, e, i) {
  var s = new Kt();
  return s.time = t.time + (e.time - t.time) * i, s.value = t.value + (e.value - t.value) * i, s;
}
function ce(t, e) {
  var i = (e - t[0].time) / (t[1].time - t[0].time);
  return i < 0 && (i = 0), t[0].value + (t[1].value - t[0].value) * i;
}
function me(t, e) {
  var i = (e - t[0].time) / (t[3].time - t[0].time);
  i < 0 && (i = 0);
  var s = _e(t[0], t[1], i),
    r = _e(t[1], t[2], i),
    a = _e(t[2], t[3], i),
    n = _e(s, r, i),
    o = _e(r, a, i);
  return _e(n, o, i).value;
}
function pe(t, e) {
  var i = e,
    s = t[0].time,
    r = t[3].time,
    a = t[1].time,
    n = t[2].time,
    o = r - 3 * n + 3 * a - s,
    l = 3 * n - 6 * a + 3 * s,
    h = 3 * a - 3 * s,
    u = s - i,
    g = Vt.cardanoAlgorithmForBezier(o, l, h, u),
    d = _e(t[0], t[1], g),
    _ = _e(t[1], t[2], g),
    c = _e(t[2], t[3], g),
    m = _e(d, _, g),
    p = _e(_, c, g);
  return _e(m, p, g).value;
}
function fe(t, e) {
  return t[0].value;
}
function ye(t, e) {
  return t[1].value;
}
function Se(t, e, i, s, r) {
  var a = t.curves.at(e);
  var n = -1;
  var o = a.baseSegmentIndex + a.segmentCount;
  var l = 0;
  for (var _e59 = a.baseSegmentIndex; _e59 < o; ++_e59) {
    if (l = t.segments.at(_e59).basePointIndex + (t.segments.at(_e59).segmentType == Wt.CubismMotionSegmentType_Bezier ? 3 : 1), t.points.at(l).time > i) {
      n = _e59;
      break;
    }
  }
  if (-1 == n) {
    return s && i < r ? function (t, e, i, s, r, a) {
      var n = [new Kt(), new Kt()];
      {
        var _e60 = t.points.at(s);
        n[0].time = _e60.time, n[0].value = _e60.value;
      }
      {
        var _e61 = t.points.at(i);
        n[1].time = a, n[1].value = _e61.value;
      }
      switch (t.segments.at(e).segmentType) {
        case Wt.CubismMotionSegmentType_Linear:
        case Wt.CubismMotionSegmentType_Bezier:
        default:
          return ce(n, r);
        case Wt.CubismMotionSegmentType_Stepped:
          return fe(n);
        case Wt.CubismMotionSegmentType_InverseStepped:
          return ye(n);
      }
    }(t, o - 1, t.segments.at(a.baseSegmentIndex).basePointIndex, l, i, r) : t.points.at(l).value;
  }
  var h = t.segments.at(n);
  return h.evaluate(t.points.get(h.basePointIndex), i);
}
var Ce, xe, Me, ve, be, Pe;
!function (t) {
  t[t.MotionBehavior_V1 = 0] = 'MotionBehavior_V1', t[t.MotionBehavior_V2 = 1] = 'MotionBehavior_V2';
}(Ce || (Ce = {}));
var Be = /*#__PURE__*/function (_Lt2) {
  (0,inherits/* default */.A)(Be, _Lt2);
  function Be() {
    var _this14;
    (0,classCallCheck/* default */.A)(this, Be);
    _this14 = (0,callSuper/* default */.A)(this, Be), _this14._motionBehavior = Ce.MotionBehavior_V2, _this14._sourceFrameRate = 30, _this14._loopDurationSeconds = -1, _this14._isLoop = !1, _this14._isLoopFadeIn = !0, _this14._lastWeight = 0, _this14._motionData = null, _this14._modelCurveIdEyeBlink = null, _this14._modelCurveIdLipSync = null, _this14._modelCurveIdOpacity = null, _this14._eyeBlinkParameterIds = null, _this14._lipSyncParameterIds = null, _this14._modelOpacity = 1, _this14._debugMode = !1;
    return _this14;
  }
  (0,createClass/* default */.A)(Be, [{
    key: "doUpdateParameters",
    value: function doUpdateParameters(t, e, i, s) {
      null == this._modelCurveIdEyeBlink && (this._modelCurveIdEyeBlink = $.getIdManager().getId('EyeBlink')), null == this._modelCurveIdLipSync && (this._modelCurveIdLipSync = $.getIdManager().getId('LipSync')), null == this._modelCurveIdOpacity && (this._modelCurveIdOpacity = $.getIdManager().getId(de)), this._motionBehavior === Ce.MotionBehavior_V2 && this._previousLoopState !== this._isLoop && (this.adjustEndTime(s), this._previousLoopState = this._isLoop);
      var r = e - s.getStartTime();
      r < 0 && (r = 0);
      var a = Number.MAX_VALUE,
        n = Number.MAX_VALUE;
      var o = 64;
      var l = 0,
        h = 0;
      this._eyeBlinkParameterIds.getSize() > o && x('too many eye blink targets : {0}', this._eyeBlinkParameterIds.getSize()), this._lipSyncParameterIds.getSize() > o && x('too many lip sync targets : {0}', this._lipSyncParameterIds.getSize());
      var u = this._fadeInSeconds <= 0 ? 1 : Vt.getEasingSine((e - s.getFadeInStartTime()) / this._fadeInSeconds),
        g = this._fadeOutSeconds <= 0 || s.getEndTime() < 0 ? 1 : Vt.getEasingSine((s.getEndTime() - e) / this._fadeOutSeconds);
      var d,
        _,
        c,
        m = r,
        p = this._motionData.duration;
      var f = this._motionBehavior === Ce.MotionBehavior_V2 && this._isLoop;
      if (this._isLoop) for (this._motionBehavior === Ce.MotionBehavior_V2 && (p += 1 / this._motionData.fps); m > p;) m -= p;
      var y = this._motionData.curves;
      for (_ = 0; _ < this._motionData.curveCount && y.at(_).type == qt.CubismMotionCurveTarget_Model; ++_) d = Se(this._motionData, _, m, f, p), y.at(_).id == this._modelCurveIdEyeBlink ? n = d : y.at(_).id == this._modelCurveIdLipSync ? a = d : y.at(_).id == this._modelCurveIdOpacity && (this._modelOpacity = d, t.setModelOapcity(this.getModelOpacityValue()));
      for (; _ < this._motionData.curveCount && y.at(_).type == qt.CubismMotionCurveTarget_Parameter; ++_) {
        if (c = t.getParameterIndex(y.at(_).id), -1 == c) continue;
        var _r9 = t.getParameterValueByIndex(c);
        if (d = Se(this._motionData, _, m, f, p), n != Number.MAX_VALUE) {
          for (var _t49 = 0; _t49 < this._eyeBlinkParameterIds.getSize() && _t49 < o; ++_t49) {
            if (this._eyeBlinkParameterIds.at(_t49) == y.at(_).id) {
              d *= n, h |= 1 << _t49;
              break;
            }
          }
        }
        if (a != Number.MAX_VALUE) {
          for (var _t50 = 0; _t50 < this._lipSyncParameterIds.getSize() && _t50 < o; ++_t50) {
            if (this._lipSyncParameterIds.at(_t50) == y.at(_).id) {
              d += a, l |= 1 << _t50;
              break;
            }
          }
        }
        var _S = void 0;
        if (t.isRepeat(c) && (d = t.getParameterRepeatValue(c, d)), y.at(_).fadeInTime < 0 && y.at(_).fadeOutTime < 0) {
          _S = _r9 + (d - _r9) * i;
        } else {
          var _t51 = void 0,
            _i36 = void 0;
          _t51 = y.at(_).fadeInTime < 0 ? u : 0 == y.at(_).fadeInTime ? 1 : Vt.getEasingSine((e - s.getFadeInStartTime()) / y.at(_).fadeInTime), _i36 = y.at(_).fadeOutTime < 0 ? g : 0 == y.at(_).fadeOutTime || s.getEndTime() < 0 ? 1 : Vt.getEasingSine((s.getEndTime() - e) / y.at(_).fadeOutTime);
          _S = _r9 + (d - _r9) * (this._weight * _t51 * _i36);
        }
        t.setParameterValueByIndex(c, _S, 1);
      }
      if (n != Number.MAX_VALUE) {
        for (var _e62 = 0; _e62 < this._eyeBlinkParameterIds.getSize() && _e62 < o; ++_e62) {
          var _s29 = t.getParameterValueById(this._eyeBlinkParameterIds.at(_e62));
          if (h >> _e62 & 1) continue;
          var _r10 = _s29 + (n - _s29) * i;
          t.setParameterValueById(this._eyeBlinkParameterIds.at(_e62), _r10);
        }
      }
      if (a != Number.MAX_VALUE) {
        for (var _e63 = 0; _e63 < this._lipSyncParameterIds.getSize() && _e63 < o; ++_e63) {
          var _s30 = t.getParameterValueById(this._lipSyncParameterIds.at(_e63));
          if (l >> _e63 & 1) continue;
          var _r11 = _s30 + (a - _s30) * i;
          t.setParameterValueById(this._lipSyncParameterIds.at(_e63), _r11);
        }
      }
      for (; _ < this._motionData.curveCount && y.at(_).type == qt.CubismMotionCurveTarget_PartOpacity; ++_) c = t.getParameterIndex(y.at(_).id), -1 != c && (d = Se(this._motionData, _, m, f, p), t.setParameterValueByIndex(c, d));
      r >= p && (this._isLoop ? this.updateForNextLoop(s, e, m) : (this._onFinishedMotion && this._onFinishedMotion(this), s.setIsFinished(!0))), this._lastWeight = i;
    }
  }, {
    key: "setIsLoop",
    value: function setIsLoop(t) {
      v('setIsLoop() is a deprecated function. Please use setLoop().'), this._isLoop = t;
    }
  }, {
    key: "isLoop",
    value: function isLoop() {
      return v('isLoop() is a deprecated function. Please use getLoop().'), this._isLoop;
    }
  }, {
    key: "setIsLoopFadeIn",
    value: function setIsLoopFadeIn(t) {
      v('setIsLoopFadeIn() is a deprecated function. Please use setLoopFadeIn().'), this._isLoopFadeIn = t;
    }
  }, {
    key: "isLoopFadeIn",
    value: function isLoopFadeIn() {
      return v('isLoopFadeIn() is a deprecated function. Please use getLoopFadeIn().'), this._isLoopFadeIn;
    }
  }, {
    key: "setMotionBehavior",
    value: function setMotionBehavior(t) {
      this._motionBehavior = t;
    }
  }, {
    key: "getMotionBehavior",
    value: function getMotionBehavior() {
      return this._motionBehavior;
    }
  }, {
    key: "getDuration",
    value: function getDuration() {
      return this._isLoop ? -1 : this._loopDurationSeconds;
    }
  }, {
    key: "getLoopDuration",
    value: function getLoopDuration() {
      return this._loopDurationSeconds;
    }
  }, {
    key: "setParameterFadeInTime",
    value: function setParameterFadeInTime(t, e) {
      var i = this._motionData.curves;
      for (var _s31 = 0; _s31 < this._motionData.curveCount; ++_s31) if (t == i.at(_s31).id) return void (i.at(_s31).fadeInTime = e);
    }
  }, {
    key: "setParameterFadeOutTime",
    value: function setParameterFadeOutTime(t, e) {
      var i = this._motionData.curves;
      for (var _s32 = 0; _s32 < this._motionData.curveCount; ++_s32) if (t == i.at(_s32).id) return void (i.at(_s32).fadeOutTime = e);
    }
  }, {
    key: "getParameterFadeInTime",
    value: function getParameterFadeInTime(t) {
      var e = this._motionData.curves;
      for (var _i37 = 0; _i37 < this._motionData.curveCount; ++_i37) if (t == e.at(_i37).id) return e.at(_i37).fadeInTime;
      return -1;
    }
  }, {
    key: "getParameterFadeOutTime",
    value: function getParameterFadeOutTime(t) {
      var e = this._motionData.curves;
      for (var _i38 = 0; _i38 < this._motionData.curveCount; ++_i38) if (t == e.at(_i38).id) return e.at(_i38).fadeOutTime;
      return -1;
    }
  }, {
    key: "setEffectIds",
    value: function setEffectIds(t, e) {
      this._eyeBlinkParameterIds = t, this._lipSyncParameterIds = e;
    }
  }, {
    key: "release",
    value: function release() {
      this._motionData = void 0, this._motionData = null;
    }
  }, {
    key: "updateForNextLoop",
    value: function updateForNextLoop(t, e, i) {
      switch (this._motionBehavior) {
        case Ce.MotionBehavior_V2:
        default:
          t.setStartTime(e - i), this._isLoopFadeIn && t.setFadeInStartTime(e - i), null != this._onFinishedMotion && this._onFinishedMotion(this);
          break;
        case Ce.MotionBehavior_V1:
          t.setStartTime(e), this._isLoopFadeIn && t.setFadeInStartTime(e);
      }
    }
  }, {
    key: "parse",
    value: function parse(t, e) {
      var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : !1;
      var s = new he(t, e);
      if (!s) return s.release(), void (s = void 0);
      if (i) {
        if (!s.hasConsistency()) return s.release(), void b('Inconsistent motion3.json.');
      }
      this._motionData = new ie(), this._motionData.duration = s.getMotionDuration(), this._motionData.loop = s.isMotionLoop(), this._motionData.curveCount = s.getMotionCurveCount(), this._motionData.fps = s.getMotionFps(), this._motionData.eventCount = s.getEventCount();
      var r = s.getEvaluationOptionFlag(ue.EvaluationOptionFlag_AreBeziersRistricted);
      s.isExistMotionFadeInTime() ? this._fadeInSeconds = s.getMotionFadeInTime() < 0 ? 1 : s.getMotionFadeInTime() : this._fadeInSeconds = 1, s.isExistMotionFadeOutTime() ? this._fadeOutSeconds = s.getMotionFadeOutTime() < 0 ? 1 : s.getMotionFadeOutTime() : this._fadeOutSeconds = 1, this._motionData.curves.updateSize(this._motionData.curveCount, te, !0), this._motionData.segments.updateSize(s.getMotionTotalSegmentCount(), Qt, !0), this._motionData.points.updateSize(s.getMotionTotalPointCount(), Kt, !0), this._motionData.events.updateSize(this._motionData.eventCount, ee, !0);
      var a = 0,
        n = 0;
      for (var _t52 = 0; _t52 < this._motionData.curveCount; ++_t52) {
        'Model' == s.getMotionCurveTarget(_t52) ? this._motionData.curves.at(_t52).type = qt.CubismMotionCurveTarget_Model : 'Parameter' == s.getMotionCurveTarget(_t52) ? this._motionData.curves.at(_t52).type = qt.CubismMotionCurveTarget_Parameter : 'PartOpacity' == s.getMotionCurveTarget(_t52) ? this._motionData.curves.at(_t52).type = qt.CubismMotionCurveTarget_PartOpacity : v('Warning : Unable to get segment type from Curve! The number of "CurveCount" may be incorrect!'), this._motionData.curves.at(_t52).id = s.getMotionCurveId(_t52), this._motionData.curves.at(_t52).baseSegmentIndex = n, this._motionData.curves.at(_t52).fadeInTime = s.isExistMotionCurveFadeInTime(_t52) ? s.getMotionCurveFadeInTime(_t52) : -1, this._motionData.curves.at(_t52).fadeOutTime = s.isExistMotionCurveFadeOutTime(_t52) ? s.getMotionCurveFadeOutTime(_t52) : -1;
        for (var _e64 = 0; _e64 < s.getMotionCurveSegmentCount(_t52);) {
          0 == _e64 ? (this._motionData.segments.at(n).basePointIndex = a, this._motionData.points.at(a).time = s.getMotionCurveSegment(_t52, _e64), this._motionData.points.at(a).value = s.getMotionCurveSegment(_t52, _e64 + 1), a += 1, _e64 += 2) : this._motionData.segments.at(n).basePointIndex = a - 1;
          switch (s.getMotionCurveSegment(_t52, _e64)) {
            case Wt.CubismMotionSegmentType_Linear:
              this._motionData.segments.at(n).segmentType = Wt.CubismMotionSegmentType_Linear, this._motionData.segments.at(n).evaluate = ce, this._motionData.points.at(a).time = s.getMotionCurveSegment(_t52, _e64 + 1), this._motionData.points.at(a).value = s.getMotionCurveSegment(_t52, _e64 + 2), a += 1, _e64 += 3;
              break;
            case Wt.CubismMotionSegmentType_Bezier:
              this._motionData.segments.at(n).segmentType = Wt.CubismMotionSegmentType_Bezier, this._motionData.segments.at(n).evaluate = r ? me : pe, this._motionData.points.at(a).time = s.getMotionCurveSegment(_t52, _e64 + 1), this._motionData.points.at(a).value = s.getMotionCurveSegment(_t52, _e64 + 2), this._motionData.points.at(a + 1).time = s.getMotionCurveSegment(_t52, _e64 + 3), this._motionData.points.at(a + 1).value = s.getMotionCurveSegment(_t52, _e64 + 4), this._motionData.points.at(a + 2).time = s.getMotionCurveSegment(_t52, _e64 + 5), this._motionData.points.at(a + 2).value = s.getMotionCurveSegment(_t52, _e64 + 6), a += 3, _e64 += 7;
              break;
            case Wt.CubismMotionSegmentType_Stepped:
              this._motionData.segments.at(n).segmentType = Wt.CubismMotionSegmentType_Stepped, this._motionData.segments.at(n).evaluate = fe, this._motionData.points.at(a).time = s.getMotionCurveSegment(_t52, _e64 + 1), this._motionData.points.at(a).value = s.getMotionCurveSegment(_t52, _e64 + 2), a += 1, _e64 += 3;
              break;
            case Wt.CubismMotionSegmentType_InverseStepped:
              this._motionData.segments.at(n).segmentType = Wt.CubismMotionSegmentType_InverseStepped, this._motionData.segments.at(n).evaluate = ye, this._motionData.points.at(a).time = s.getMotionCurveSegment(_t52, _e64 + 1), this._motionData.points.at(a).value = s.getMotionCurveSegment(_t52, _e64 + 2), a += 1, _e64 += 3;
              break;
            default:
              C(0);
          }
          ++this._motionData.curves.at(_t52).segmentCount, ++n;
        }
      }
      for (var _t53 = 0; _t53 < s.getEventCount(); ++_t53) this._motionData.events.at(_t53).fireTime = s.getEventTime(_t53), this._motionData.events.at(_t53).value = s.getEventValue(_t53);
      s.release(), s = void 0, s = null;
    }
  }, {
    key: "getFiredEvent",
    value: function getFiredEvent(t, e) {
      this._firedEventValues.updateSize(0);
      for (var _i39 = 0; _i39 < this._motionData.eventCount; ++_i39) this._motionData.events.at(_i39).fireTime > t && this._motionData.events.at(_i39).fireTime <= e && this._firedEventValues.pushBack(new g(this._motionData.events.at(_i39).value.s));
      return this._firedEventValues;
    }
  }, {
    key: "isExistModelOpacity",
    value: function isExistModelOpacity() {
      for (var _t54 = 0; _t54 < this._motionData.curveCount; _t54++) {
        var _e65 = this._motionData.curves.at(_t54);
        if (_e65.type == qt.CubismMotionCurveTarget_Model && 0 == _e65.id.getString().s.localeCompare(de)) return !0;
      }
      return !1;
    }
  }, {
    key: "getModelOpacityIndex",
    value: function getModelOpacityIndex() {
      if (this.isExistModelOpacity()) {
        for (var _t55 = 0; _t55 < this._motionData.curveCount; _t55++) {
          var _e66 = this._motionData.curves.at(_t55);
          if (_e66.type == qt.CubismMotionCurveTarget_Model && 0 == _e66.id.getString().s.localeCompare(de)) return _t55;
        }
      }
      return -1;
    }
  }, {
    key: "getModelOpacityId",
    value: function getModelOpacityId(t) {
      if (-1 != t) {
        var _e67 = this._motionData.curves.at(t);
        if (_e67.type == qt.CubismMotionCurveTarget_Model && 0 == _e67.id.getString().s.localeCompare(de)) return $.getIdManager().getId(_e67.id.getString().s);
      }
      return null;
    }
  }, {
    key: "getModelOpacityValue",
    value: function getModelOpacityValue() {
      return this._modelOpacity;
    }
  }, {
    key: "setDebugMode",
    value: function setDebugMode(t) {
      this._debugMode = t;
    }
  }], [{
    key: "create",
    value: function create(t, e, i, s) {
      var r = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : !1;
      var a = new Be();
      return a.parse(t, e, r), a._motionData ? (a._sourceFrameRate = a._motionData.fps, a._loopDurationSeconds = a._motionData.duration, a._onFinishedMotion = i, a._onBeganMotion = s, a) : (J(a), null);
    }
  }]);
  return Be;
}(Lt);
(xe || (xe = {})).CubismMotion = Be;
var we = /*#__PURE__*/function (_Xt2) {
  (0,inherits/* default */.A)(we, _Xt2);
  function we() {
    var _this15;
    (0,classCallCheck/* default */.A)(this, we);
    _this15 = (0,callSuper/* default */.A)(this, we), _this15._currentPriority = 0, _this15._reservePriority = 0;
    return _this15;
  }
  (0,createClass/* default */.A)(we, [{
    key: "getCurrentPriority",
    value: function getCurrentPriority() {
      return this._currentPriority;
    }
  }, {
    key: "getReservePriority",
    value: function getReservePriority() {
      return this._reservePriority;
    }
  }, {
    key: "setReservePriority",
    value: function setReservePriority(t) {
      this._reservePriority = t;
    }
  }, {
    key: "startMotionPriority",
    value: function startMotionPriority(t, e, i) {
      return i == this._reservePriority && (this._reservePriority = 0), this._currentPriority = i, _get((0,getPrototypeOf/* default */.A)(we.prototype), "startMotion", this).call(this, t, e);
    }
  }, {
    key: "updateMotion",
    value: function updateMotion(t, e) {
      this._userTimeSeconds += e;
      var i = _get((0,getPrototypeOf/* default */.A)(we.prototype), "doUpdateMotion", this).call(this, t, this._userTimeSeconds);
      return this.isFinished() && (this._currentPriority = 0), i;
    }
  }, {
    key: "reserveMotion",
    value: function reserveMotion(t) {
      return !(t <= this._reservePriority || t <= this._currentPriority) && (this._reservePriority = t, !0);
    }
  }]);
  return we;
}(Xt);
(Me || (Me = {})).CubismMotionManager = we, function (t) {
  t[t.CubismPhysicsTargetType_Parameter = 0] = 'CubismPhysicsTargetType_Parameter';
}(ve || (ve = {})), function (t) {
  t[t.CubismPhysicsSource_X = 0] = 'CubismPhysicsSource_X', t[t.CubismPhysicsSource_Y = 1] = 'CubismPhysicsSource_Y', t[t.CubismPhysicsSource_Angle = 2] = 'CubismPhysicsSource_Angle';
}(be || (be = {}));
var Fe = /*#__PURE__*/(0,createClass/* default */.A)(function Fe() {
  (0,classCallCheck/* default */.A)(this, Fe);
  this.gravity = new It(0, 0), this.wind = new It(0, 0);
});
var Ie = /*#__PURE__*/(0,createClass/* default */.A)(function Ie() {
  (0,classCallCheck/* default */.A)(this, Ie);
});
var Ve = /*#__PURE__*/(0,createClass/* default */.A)(function Ve() {
  (0,classCallCheck/* default */.A)(this, Ve);
});
var Ee = /*#__PURE__*/(0,createClass/* default */.A)(function Ee() {
  (0,classCallCheck/* default */.A)(this, Ee);
  this.initialPosition = new It(0, 0), this.position = new It(0, 0), this.lastPosition = new It(0, 0), this.lastGravity = new It(0, 0), this.force = new It(0, 0), this.velocity = new It(0, 0);
});
var Re = /*#__PURE__*/(0,createClass/* default */.A)(function Re() {
  (0,classCallCheck/* default */.A)(this, Re);
  this.normalizationPosition = new Ve(), this.normalizationAngle = new Ve();
});
var Te = /*#__PURE__*/(0,createClass/* default */.A)(function Te() {
  (0,classCallCheck/* default */.A)(this, Te);
  this.source = new Ie();
});
var Le = /*#__PURE__*/(0,createClass/* default */.A)(function Le() {
  (0,classCallCheck/* default */.A)(this, Le);
  this.destination = new Ie(), this.translationScale = new It(0, 0);
});
var De = /*#__PURE__*/(0,createClass/* default */.A)(function De() {
  (0,classCallCheck/* default */.A)(this, De);
  this.settings = new e(), this.inputs = new e(), this.outputs = new e(), this.particles = new e(), this.gravity = new It(0, 0), this.wind = new It(0, 0), this.fps = 0;
});
!function (t) {
  t.CubismPhysicsInput = Te, t.CubismPhysicsNormalization = Ve, t.CubismPhysicsOutput = Le, t.CubismPhysicsParameter = Ie, t.CubismPhysicsParticle = Ee, t.CubismPhysicsRig = De, t.CubismPhysicsSource = be, t.CubismPhysicsSubRig = Re, t.CubismPhysicsTargetType = ve, t.PhysicsJsonEffectiveForces = Fe;
}(Pe || (Pe = {}));
var Ae = 'Position',
  Oe = 'Angle',
  ke = 'Type',
  Ne = 'Meta',
  ze = 'EffectiveForces',
  Ue = 'Gravity',
  Ge = 'Wind',
  Xe = 'PhysicsSettings',
  Ye = 'Normalization',
  je = 'Minimum',
  He = 'Maximum',
  qe = 'Default',
  We = 'Reflect',
  Je = 'Weight',
  $e = 'Input',
  Ze = 'Output',
  Ke = 'Vertices';
var Qe = /*#__PURE__*/function () {
  function Qe(t, e) {
    (0,classCallCheck/* default */.A)(this, Qe);
    this._json = L.create(t, e);
  }
  (0,createClass/* default */.A)(Qe, [{
    key: "release",
    value: function release() {
      L.delete(this._json);
    }
  }, {
    key: "getGravity",
    value: function getGravity() {
      var t = new It(0, 0);
      return t.x = this._json.getRoot().getValueByString(Ne).getValueByString(ze).getValueByString(Ue).getValueByString('X').toFloat(), t.y = this._json.getRoot().getValueByString(Ne).getValueByString(ze).getValueByString(Ue).getValueByString('Y').toFloat(), t;
    }
  }, {
    key: "getWind",
    value: function getWind() {
      var t = new It(0, 0);
      return t.x = this._json.getRoot().getValueByString(Ne).getValueByString(ze).getValueByString(Ge).getValueByString('X').toFloat(), t.y = this._json.getRoot().getValueByString(Ne).getValueByString(ze).getValueByString(Ge).getValueByString('Y').toFloat(), t;
    }
  }, {
    key: "getFps",
    value: function getFps() {
      return this._json.getRoot().getValueByString(Ne).getValueByString('Fps').toFloat(0);
    }
  }, {
    key: "getSubRigCount",
    value: function getSubRigCount() {
      return this._json.getRoot().getValueByString(Ne).getValueByString('PhysicsSettingCount').toInt();
    }
  }, {
    key: "getTotalInputCount",
    value: function getTotalInputCount() {
      return this._json.getRoot().getValueByString(Ne).getValueByString('TotalInputCount').toInt();
    }
  }, {
    key: "getTotalOutputCount",
    value: function getTotalOutputCount() {
      return this._json.getRoot().getValueByString(Ne).getValueByString('TotalOutputCount').toInt();
    }
  }, {
    key: "getVertexCount",
    value: function getVertexCount() {
      return this._json.getRoot().getValueByString(Ne).getValueByString('VertexCount').toInt();
    }
  }, {
    key: "getNormalizationPositionMinimumValue",
    value: function getNormalizationPositionMinimumValue(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ye).getValueByString(Ae).getValueByString(je).toFloat();
    }
  }, {
    key: "getNormalizationPositionMaximumValue",
    value: function getNormalizationPositionMaximumValue(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ye).getValueByString(Ae).getValueByString(He).toFloat();
    }
  }, {
    key: "getNormalizationPositionDefaultValue",
    value: function getNormalizationPositionDefaultValue(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ye).getValueByString(Ae).getValueByString(qe).toFloat();
    }
  }, {
    key: "getNormalizationAngleMinimumValue",
    value: function getNormalizationAngleMinimumValue(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ye).getValueByString(Oe).getValueByString(je).toFloat();
    }
  }, {
    key: "getNormalizationAngleMaximumValue",
    value: function getNormalizationAngleMaximumValue(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ye).getValueByString(Oe).getValueByString(He).toFloat();
    }
  }, {
    key: "getNormalizationAngleDefaultValue",
    value: function getNormalizationAngleDefaultValue(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ye).getValueByString(Oe).getValueByString(qe).toFloat();
    }
  }, {
    key: "getInputCount",
    value: function getInputCount(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString($e).getVector().getSize();
    }
  }, {
    key: "getInputWeight",
    value: function getInputWeight(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString($e).getValueByIndex(e).getValueByString(Je).toFloat();
    }
  }, {
    key: "getInputReflect",
    value: function getInputReflect(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString($e).getValueByIndex(e).getValueByString(We).toBoolean();
    }
  }, {
    key: "getInputType",
    value: function getInputType(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString($e).getValueByIndex(e).getValueByString(ke).getRawString();
    }
  }, {
    key: "getInputSourceId",
    value: function getInputSourceId(t, e) {
      return $.getIdManager().getId(this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString($e).getValueByIndex(e).getValueByString('Source').getValueByString('Id').getRawString());
    }
  }, {
    key: "getOutputCount",
    value: function getOutputCount(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ze).getVector().getSize();
    }
  }, {
    key: "getOutputVertexIndex",
    value: function getOutputVertexIndex(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ze).getValueByIndex(e).getValueByString('VertexIndex').toInt();
    }
  }, {
    key: "getOutputAngleScale",
    value: function getOutputAngleScale(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ze).getValueByIndex(e).getValueByString('Scale').toFloat();
    }
  }, {
    key: "getOutputWeight",
    value: function getOutputWeight(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ze).getValueByIndex(e).getValueByString(Je).toFloat();
    }
  }, {
    key: "getOutputDestinationId",
    value: function getOutputDestinationId(t, e) {
      return $.getIdManager().getId(this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ze).getValueByIndex(e).getValueByString('Destination').getValueByString('Id').getRawString());
    }
  }, {
    key: "getOutputType",
    value: function getOutputType(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ze).getValueByIndex(e).getValueByString(ke).getRawString();
    }
  }, {
    key: "getOutputReflect",
    value: function getOutputReflect(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ze).getValueByIndex(e).getValueByString(We).toBoolean();
    }
  }, {
    key: "getParticleCount",
    value: function getParticleCount(t) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ke).getVector().getSize();
    }
  }, {
    key: "getParticleMobility",
    value: function getParticleMobility(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ke).getValueByIndex(e).getValueByString('Mobility').toFloat();
    }
  }, {
    key: "getParticleDelay",
    value: function getParticleDelay(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ke).getValueByIndex(e).getValueByString('Delay').toFloat();
    }
  }, {
    key: "getParticleAcceleration",
    value: function getParticleAcceleration(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ke).getValueByIndex(e).getValueByString('Acceleration').toFloat();
    }
  }, {
    key: "getParticleRadius",
    value: function getParticleRadius(t, e) {
      return this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ke).getValueByIndex(e).getValueByString('Radius').toFloat();
    }
  }, {
    key: "getParticlePosition",
    value: function getParticlePosition(t, e) {
      var i = new It(0, 0);
      return i.x = this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ke).getValueByIndex(e).getValueByString(Ae).getValueByString('X').toFloat(), i.y = this._json.getRoot().getValueByString(Xe).getValueByIndex(t).getValueByString(Ke).getValueByIndex(e).getValueByString(Ae).getValueByString('Y').toFloat(), i;
    }
  }]);
  return Qe;
}();
var ti;
(ti || (ti = {})).CubismPhysicsJson = Qe;
var ei = 'Angle';
var ii = /*#__PURE__*/function () {
  function ii() {
    (0,classCallCheck/* default */.A)(this, ii);
    this._physicsRig = null, this._options = new si(), this._options.gravity.y = -1, this._options.gravity.x = 0, this._options.wind.x = 0, this._options.wind.y = 0, this._currentRigOutputs = new e(), this._previousRigOutputs = new e(), this._currentRemainTime = 0, this._parameterCaches = null, this._parameterInputCaches = null;
  }
  (0,createClass/* default */.A)(ii, [{
    key: "parse",
    value: function parse(t, e) {
      this._physicsRig = new De();
      var i = new Qe(t, e);
      this._physicsRig.gravity = i.getGravity(), this._physicsRig.wind = i.getWind(), this._physicsRig.subRigCount = i.getSubRigCount(), this._physicsRig.fps = i.getFps(), this._physicsRig.settings.updateSize(this._physicsRig.subRigCount, Re, !0), this._physicsRig.inputs.updateSize(i.getTotalInputCount(), Te, !0), this._physicsRig.outputs.updateSize(i.getTotalOutputCount(), Le, !0), this._physicsRig.particles.updateSize(i.getVertexCount(), Ee, !0), this._currentRigOutputs.clear(), this._previousRigOutputs.clear();
      var s = 0,
        r = 0,
        a = 0;
      for (var _t56 = 0; _t56 < this._physicsRig.settings.getSize(); ++_t56) {
        this._physicsRig.settings.at(_t56).normalizationPosition.minimum = i.getNormalizationPositionMinimumValue(_t56), this._physicsRig.settings.at(_t56).normalizationPosition.maximum = i.getNormalizationPositionMaximumValue(_t56), this._physicsRig.settings.at(_t56).normalizationPosition.defalut = i.getNormalizationPositionDefaultValue(_t56), this._physicsRig.settings.at(_t56).normalizationAngle.minimum = i.getNormalizationAngleMinimumValue(_t56), this._physicsRig.settings.at(_t56).normalizationAngle.maximum = i.getNormalizationAngleMaximumValue(_t56), this._physicsRig.settings.at(_t56).normalizationAngle.defalut = i.getNormalizationAngleDefaultValue(_t56), this._physicsRig.settings.at(_t56).inputCount = i.getInputCount(_t56), this._physicsRig.settings.at(_t56).baseInputIndex = s;
        for (var _e68 = 0; _e68 < this._physicsRig.settings.at(_t56).inputCount; ++_e68) this._physicsRig.inputs.at(s + _e68).sourceParameterIndex = -1, this._physicsRig.inputs.at(s + _e68).weight = i.getInputWeight(_t56, _e68), this._physicsRig.inputs.at(s + _e68).reflect = i.getInputReflect(_t56, _e68), 'X' == i.getInputType(_t56, _e68) ? (this._physicsRig.inputs.at(s + _e68).type = be.CubismPhysicsSource_X, this._physicsRig.inputs.at(s + _e68).getNormalizedParameterValue = ai) : 'Y' == i.getInputType(_t56, _e68) ? (this._physicsRig.inputs.at(s + _e68).type = be.CubismPhysicsSource_Y, this._physicsRig.inputs.at(s + _e68).getNormalizedParameterValue = ni) : i.getInputType(_t56, _e68) == ei && (this._physicsRig.inputs.at(s + _e68).type = be.CubismPhysicsSource_Angle, this._physicsRig.inputs.at(s + _e68).getNormalizedParameterValue = oi), this._physicsRig.inputs.at(s + _e68).source.targetType = ve.CubismPhysicsTargetType_Parameter, this._physicsRig.inputs.at(s + _e68).source.id = i.getInputSourceId(_t56, _e68);
        s += this._physicsRig.settings.at(_t56).inputCount, this._physicsRig.settings.at(_t56).outputCount = i.getOutputCount(_t56), this._physicsRig.settings.at(_t56).baseOutputIndex = r;
        var _e69 = new ri();
        _e69.outputs.resize(this._physicsRig.settings.at(_t56).outputCount);
        var _n7 = new ri();
        _n7.outputs.resize(this._physicsRig.settings.at(_t56).outputCount);
        for (var _s33 = 0; _s33 < this._physicsRig.settings.at(_t56).outputCount; ++_s33) _e69.outputs.set(_s33, 0), _n7.outputs.set(_s33, 0), this._physicsRig.outputs.at(r + _s33).destinationParameterIndex = -1, this._physicsRig.outputs.at(r + _s33).vertexIndex = i.getOutputVertexIndex(_t56, _s33), this._physicsRig.outputs.at(r + _s33).angleScale = i.getOutputAngleScale(_t56, _s33), this._physicsRig.outputs.at(r + _s33).weight = i.getOutputWeight(_t56, _s33), this._physicsRig.outputs.at(r + _s33).destination.targetType = ve.CubismPhysicsTargetType_Parameter, this._physicsRig.outputs.at(r + _s33).destination.id = i.getOutputDestinationId(_t56, _s33), 'X' == i.getOutputType(_t56, _s33) ? (this._physicsRig.outputs.at(r + _s33).type = be.CubismPhysicsSource_X, this._physicsRig.outputs.at(r + _s33).getValue = li, this._physicsRig.outputs.at(r + _s33).getScale = di) : 'Y' == i.getOutputType(_t56, _s33) ? (this._physicsRig.outputs.at(r + _s33).type = be.CubismPhysicsSource_Y, this._physicsRig.outputs.at(r + _s33).getValue = hi, this._physicsRig.outputs.at(r + _s33).getScale = _i) : i.getOutputType(_t56, _s33) == ei && (this._physicsRig.outputs.at(r + _s33).type = be.CubismPhysicsSource_Angle, this._physicsRig.outputs.at(r + _s33).getValue = ui, this._physicsRig.outputs.at(r + _s33).getScale = ci), this._physicsRig.outputs.at(r + _s33).reflect = i.getOutputReflect(_t56, _s33);
        this._currentRigOutputs.pushBack(_e69), this._previousRigOutputs.pushBack(_n7), r += this._physicsRig.settings.at(_t56).outputCount, this._physicsRig.settings.at(_t56).particleCount = i.getParticleCount(_t56), this._physicsRig.settings.at(_t56).baseParticleIndex = a;
        for (var _e70 = 0; _e70 < this._physicsRig.settings.at(_t56).particleCount; ++_e70) this._physicsRig.particles.at(a + _e70).mobility = i.getParticleMobility(_t56, _e70), this._physicsRig.particles.at(a + _e70).delay = i.getParticleDelay(_t56, _e70), this._physicsRig.particles.at(a + _e70).acceleration = i.getParticleAcceleration(_t56, _e70), this._physicsRig.particles.at(a + _e70).radius = i.getParticleRadius(_t56, _e70), this._physicsRig.particles.at(a + _e70).position = i.getParticlePosition(_t56, _e70);
        a += this._physicsRig.settings.at(_t56).particleCount;
      }
      this.initialize(), i.release(), i = void 0, i = null;
    }
  }, {
    key: "stabilization",
    value: function stabilization(t) {
      var e, i, s, r;
      var a, n, o, l;
      var h = new It();
      var u, g, d, _;
      var c = t.getModel().parameters.values,
        m = t.getModel().parameters.maximumValues,
        p = t.getModel().parameters.minimumValues,
        f = t.getModel().parameters.defaultValues;
      (null !== (i = null === (e = this._parameterCaches) || void 0 === e ? void 0 : e.length) && void 0 !== i ? i : 0) < t.getParameterCount() && (this._parameterCaches = new Float32Array(t.getParameterCount())), (null !== (r = null === (s = this._parameterInputCaches) || void 0 === s ? void 0 : s.length) && void 0 !== r ? r : 0) < t.getParameterCount() && (this._parameterInputCaches = new Float32Array(t.getParameterCount()));
      for (var _e71 = 0; _e71 < t.getParameterCount(); ++_e71) this._parameterCaches[_e71] = c[_e71], this._parameterInputCaches[_e71] = c[_e71];
      for (var _e72 = 0; _e72 < this._physicsRig.subRigCount; ++_e72) {
        a = {
          angle: 0
        }, h.x = 0, h.y = 0, u = this._physicsRig.settings.at(_e72), g = this._physicsRig.inputs.get(u.baseInputIndex), d = this._physicsRig.outputs.get(u.baseOutputIndex), _ = this._physicsRig.particles.get(u.baseParticleIndex);
        for (var _e73 = 0; _e73 < u.inputCount; ++_e73) n = g[_e73].weight / 100, -1 == g[_e73].sourceParameterIndex && (g[_e73].sourceParameterIndex = t.getParameterIndex(g[_e73].source.id)), g[_e73].getNormalizedParameterValue(h, a, c[g[_e73].sourceParameterIndex], p[g[_e73].sourceParameterIndex], m[g[_e73].sourceParameterIndex], f[g[_e73].sourceParameterIndex], u.normalizationPosition, u.normalizationAngle, g[_e73].reflect, n), this._parameterCaches[g[_e73].sourceParameterIndex] = c[g[_e73].sourceParameterIndex];
        o = Vt.degreesToRadian(-a.angle), h.x = h.x * Vt.cos(o) - h.y * Vt.sin(o), h.y = h.x * Vt.sin(o) + h.y * Vt.cos(o), pi(_, u.particleCount, h, a.angle, this._options.wind, .001 * u.normalizationPosition.maximum);
        for (var _i40 = 0; _i40 < u.outputCount; ++_i40) {
          var _s34 = d[_i40].vertexIndex;
          if (-1 == d[_i40].destinationParameterIndex && (d[_i40].destinationParameterIndex = t.getParameterIndex(d[_i40].destination.id)), _s34 < 1 || _s34 >= u.particleCount) continue;
          var _r12 = new It();
          _r12 = _[_s34].position.substract(_[_s34 - 1].position), l = d[_i40].getValue(_r12, _, _s34, d[_i40].reflect, this._options.gravity), this._currentRigOutputs.at(_e72).outputs.set(_i40, l), this._previousRigOutputs.at(_e72).outputs.set(_i40, l);
          var _a7 = d[_i40].destinationParameterIndex,
            _n8 = !Float32Array.prototype.slice && 'subarray' in Float32Array.prototype ? JSON.parse(JSON.stringify(c.subarray(_a7))) : c.slice(_a7);
          fi(_n8, p[_a7], m[_a7], l, d[_i40]);
          for (var _t57 = _a7, _e74 = 0; _t57 < this._parameterCaches.length; _t57++, _e74++) c[_t57] = this._parameterCaches[_t57] = _n8[_e74];
        }
      }
    }
  }, {
    key: "evaluate",
    value: function evaluate(t, e) {
      var i, s, r, a;
      var n, o, l, h;
      var u = new It();
      var g, d, _, c;
      if (0 >= e) return;
      var m = t.getModel().parameters.values,
        p = t.getModel().parameters.maximumValues,
        f = t.getModel().parameters.minimumValues,
        y = t.getModel().parameters.defaultValues;
      var S;
      if (this._currentRemainTime += e, this._currentRemainTime > 5 && (this._currentRemainTime = 0), (null !== (s = null === (i = this._parameterCaches) || void 0 === i ? void 0 : i.length) && void 0 !== s ? s : 0) < t.getParameterCount() && (this._parameterCaches = new Float32Array(t.getParameterCount())), (null !== (a = null === (r = this._parameterInputCaches) || void 0 === r ? void 0 : r.length) && void 0 !== a ? a : 0) < t.getParameterCount()) {
        this._parameterInputCaches = new Float32Array(t.getParameterCount());
        for (var _e75 = 0; _e75 < t.getParameterCount(); ++_e75) this._parameterInputCaches[_e75] = m[_e75];
      }
      for (S = this._physicsRig.fps > 0 ? 1 / this._physicsRig.fps : e; this._currentRemainTime >= S;) {
        for (var _t58 = 0; _t58 < this._physicsRig.subRigCount; ++_t58) {
          g = this._physicsRig.settings.at(_t58), _ = this._physicsRig.outputs.get(g.baseOutputIndex);
          for (var _e76 = 0; _e76 < g.outputCount; ++_e76) this._previousRigOutputs.at(_t58).outputs.set(_e76, this._currentRigOutputs.at(_t58).outputs.at(_e76));
        }
        var _e77 = S / this._currentRemainTime;
        for (var _i41 = 0; _i41 < t.getParameterCount(); ++_i41) this._parameterCaches[_i41] = this._parameterInputCaches[_i41] * (1 - _e77) + m[_i41] * _e77, this._parameterInputCaches[_i41] = this._parameterCaches[_i41];
        for (var _e78 = 0; _e78 < this._physicsRig.subRigCount; ++_e78) {
          n = {
            angle: 0
          }, u.x = 0, u.y = 0, g = this._physicsRig.settings.at(_e78), d = this._physicsRig.inputs.get(g.baseInputIndex), _ = this._physicsRig.outputs.get(g.baseOutputIndex), c = this._physicsRig.particles.get(g.baseParticleIndex);
          for (var _e79 = 0; _e79 < g.inputCount; ++_e79) o = d[_e79].weight / 100, -1 == d[_e79].sourceParameterIndex && (d[_e79].sourceParameterIndex = t.getParameterIndex(d[_e79].source.id)), d[_e79].getNormalizedParameterValue(u, n, this._parameterCaches[d[_e79].sourceParameterIndex], f[d[_e79].sourceParameterIndex], p[d[_e79].sourceParameterIndex], y[d[_e79].sourceParameterIndex], g.normalizationPosition, g.normalizationAngle, d[_e79].reflect, o);
          l = Vt.degreesToRadian(-n.angle), u.x = u.x * Vt.cos(l) - u.y * Vt.sin(l), u.y = u.x * Vt.sin(l) + u.y * Vt.cos(l), mi(c, g.particleCount, u, n.angle, this._options.wind, .001 * g.normalizationPosition.maximum, S, 5);
          for (var _i42 = 0; _i42 < g.outputCount; ++_i42) {
            var _s35 = _[_i42].vertexIndex;
            if (-1 == _[_i42].destinationParameterIndex && (_[_i42].destinationParameterIndex = t.getParameterIndex(_[_i42].destination.id)), _s35 < 1 || _s35 >= g.particleCount) continue;
            var _r13 = new It();
            _r13.x = c[_s35].position.x - c[_s35 - 1].position.x, _r13.y = c[_s35].position.y - c[_s35 - 1].position.y, h = _[_i42].getValue(_r13, c, _s35, _[_i42].reflect, this._options.gravity), this._currentRigOutputs.at(_e78).outputs.set(_i42, h);
            var _a8 = _[_i42].destinationParameterIndex,
              _n9 = !Float32Array.prototype.slice && 'subarray' in Float32Array.prototype ? JSON.parse(JSON.stringify(this._parameterCaches.subarray(_a8))) : this._parameterCaches.slice(_a8);
            fi(_n9, f[_a8], p[_a8], h, _[_i42]);
            for (var _t59 = _a8, _e80 = 0; _t59 < this._parameterCaches.length; _t59++, _e80++) this._parameterCaches[_t59] = _n9[_e80];
          }
        }
        this._currentRemainTime -= S;
      }
      var C = this._currentRemainTime / S;
      this.interpolate(t, C);
    }
  }, {
    key: "interpolate",
    value: function interpolate(t, e) {
      var i, s;
      var r = t.getModel().parameters.values,
        a = t.getModel().parameters.maximumValues,
        n = t.getModel().parameters.minimumValues;
      for (var _t60 = 0; _t60 < this._physicsRig.subRigCount; ++_t60) {
        s = this._physicsRig.settings.at(_t60), i = this._physicsRig.outputs.get(s.baseOutputIndex);
        for (var _o4 = 0; _o4 < s.outputCount; ++_o4) {
          if (-1 == i[_o4].destinationParameterIndex) continue;
          var _s36 = i[_o4].destinationParameterIndex,
            _l3 = !Float32Array.prototype.slice && 'subarray' in Float32Array.prototype ? JSON.parse(JSON.stringify(r.subarray(_s36))) : r.slice(_s36);
          fi(_l3, n[_s36], a[_s36], this._previousRigOutputs.at(_t60).outputs.at(_o4) * (1 - e) + this._currentRigOutputs.at(_t60).outputs.at(_o4) * e, i[_o4]);
          for (var _t61 = _s36, _e81 = 0; _t61 < r.length; _t61++, _e81++) r[_t61] = _l3[_e81];
        }
      }
    }
  }, {
    key: "setOptions",
    value: function setOptions(t) {
      this._options = t;
    }
  }, {
    key: "getOption",
    value: function getOption() {
      return this._options;
    }
  }, {
    key: "release",
    value: function release() {
      this._physicsRig = void 0, this._physicsRig = null;
    }
  }, {
    key: "initialize",
    value: function initialize() {
      var t, e, i;
      for (var _s37 = 0; _s37 < this._physicsRig.subRigCount; ++_s37) {
        e = this._physicsRig.settings.at(_s37), t = this._physicsRig.particles.get(e.baseParticleIndex), t[0].initialPosition = new It(0, 0), t[0].lastPosition = new It(t[0].initialPosition.x, t[0].initialPosition.y), t[0].lastGravity = new It(0, -1), t[0].lastGravity.y *= -1, t[0].velocity = new It(0, 0), t[0].force = new It(0, 0);
        for (var _s38 = 1; _s38 < e.particleCount; ++_s38) i = new It(0, 0), i.y = t[_s38].radius, t[_s38].initialPosition = new It(t[_s38 - 1].initialPosition.x + i.x, t[_s38 - 1].initialPosition.y + i.y), t[_s38].position = new It(t[_s38].initialPosition.x, t[_s38].initialPosition.y), t[_s38].lastPosition = new It(t[_s38].initialPosition.x, t[_s38].initialPosition.y), t[_s38].lastGravity = new It(0, -1), t[_s38].lastGravity.y *= -1, t[_s38].velocity = new It(0, 0), t[_s38].force = new It(0, 0);
      }
    }
  }], [{
    key: "create",
    value: function create(t, e) {
      var i = new ii();
      return i.parse(t, e), i._physicsRig.gravity.y = 0, i;
    }
  }, {
    key: "delete",
    value: function _delete(t) {
      null != t && (t.release(), t = null);
    }
  }]);
  return ii;
}();
var si = /*#__PURE__*/(0,createClass/* default */.A)(function si() {
  (0,classCallCheck/* default */.A)(this, si);
  this.gravity = new It(0, 0), this.wind = new It(0, 0);
});
var ri = /*#__PURE__*/(0,createClass/* default */.A)(function ri() {
  (0,classCallCheck/* default */.A)(this, ri);
  this.outputs = new e(0);
});
function ai(t, e, i, s, r, a, n, o, l, h) {
  t.x += yi(i, s, r, a, n.minimum, n.maximum, n.defalut, l) * h;
}
function ni(t, e, i, s, r, a, n, o, l, h) {
  t.y += yi(i, s, r, a, n.minimum, n.maximum, n.defalut, l) * h;
}
function oi(t, e, i, s, r, a, n, o, l, h) {
  e.angle += yi(i, s, r, a, o.minimum, o.maximum, o.defalut, l) * h;
}
function li(t, e, i, s, r) {
  var a = t.x;
  return s && (a *= -1), a;
}
function hi(t, e, i, s, r) {
  var a = t.y;
  return s && (a *= -1), a;
}
function ui(t, e, i, s, r) {
  var a;
  return r = i >= 2 ? e[i - 1].position.substract(e[i - 2].position) : r.multiplyByScaler(-1), a = Vt.directionToRadian(r, t), s && (a *= -1), a;
}
function gi(t, e) {
  return Vt.min(t, e) + function (t, e) {
    var i = Vt.max(t, e),
      s = Vt.min(t, e);
    return Vt.abs(i - s);
  }(t, e) / 2;
}
function di(t, e) {
  return JSON.parse(JSON.stringify(t.x));
}
function _i(t, e) {
  return JSON.parse(JSON.stringify(t.y));
}
function ci(t, e) {
  return JSON.parse(JSON.stringify(e));
}
function mi(t, e, i, s, r, a, n, o) {
  var l,
    h,
    u = new It(0, 0),
    g = new It(0, 0),
    d = new It(0, 0),
    _ = new It(0, 0);
  t[0].position = new It(i.x, i.y);
  var c = Vt.degreesToRadian(s),
    m = Vt.radianToDirection(c);
  m.normalize();
  for (var _i43 = 1; _i43 < e; ++_i43) t[_i43].force = m.multiplyByScaler(t[_i43].acceleration).add(r), t[_i43].lastPosition = new It(t[_i43].position.x, t[_i43].position.y), l = t[_i43].delay * n * 30, u = t[_i43].position.substract(t[_i43 - 1].position), h = Vt.directionToRadian(t[_i43].lastGravity, m) / o, u.x = Vt.cos(h) * u.x - u.y * Vt.sin(h), u.y = Vt.sin(h) * u.x + u.y * Vt.cos(h), t[_i43].position = t[_i43 - 1].position.add(u), g = t[_i43].velocity.multiplyByScaler(l), d = t[_i43].force.multiplyByScaler(l).multiplyByScaler(l), t[_i43].position = t[_i43].position.add(g).add(d), _ = t[_i43].position.substract(t[_i43 - 1].position), _.normalize(), t[_i43].position = t[_i43 - 1].position.add(_.multiplyByScaler(t[_i43].radius)), Vt.abs(t[_i43].position.x) < a && (t[_i43].position.x = 0), 0 != l && (t[_i43].velocity = t[_i43].position.substract(t[_i43].lastPosition), t[_i43].velocity = t[_i43].velocity.divisionByScalar(l), t[_i43].velocity = t[_i43].velocity.multiplyByScaler(t[_i43].mobility)), t[_i43].force = new It(0, 0), t[_i43].lastGravity = new It(m.x, m.y);
}
function pi(t, e, i, s, r, a) {
  var n = new It(0, 0);
  t[0].position = new It(i.x, i.y);
  var o = Vt.degreesToRadian(s),
    l = Vt.radianToDirection(o);
  l.normalize();
  for (var _i44 = 1; _i44 < e; ++_i44) t[_i44].force = l.multiplyByScaler(t[_i44].acceleration).add(r), t[_i44].lastPosition = new It(t[_i44].position.x, t[_i44].position.y), t[_i44].velocity = new It(0, 0), n = t[_i44].force, n.normalize(), n = n.multiplyByScaler(t[_i44].radius), t[_i44].position = t[_i44 - 1].position.add(n), Vt.abs(t[_i44].position.x) < a && (t[_i44].position.x = 0), t[_i44].force = new It(0, 0), t[_i44].lastGravity = new It(l.x, l.y);
}
function fi(t, e, i, s, r) {
  var a;
  a = s * r.getScale(r.translationScale, r.angleScale), a < e ? (a < r.valueBelowMinimum && (r.valueBelowMinimum = a), a = e) : a > i && (a > r.valueExceededMaximum && (r.valueExceededMaximum = a), a = i);
  var n = r.weight / 100;
  n >= 1 || (a = t[0] * (1 - n) + a * n), t[0] = a;
}
function yi(t, e, i, s, r, a, n, o) {
  var l = 0;
  var h = Vt.max(i, e);
  h < t && (t = h);
  var u = Vt.min(i, e);
  u > t && (t = u);
  var g = Vt.min(r, a),
    d = Vt.max(r, a),
    _ = n,
    c = gi(u, h),
    m = t - c;
  switch (function (t) {
    var e = 0;
    return t > 0 ? e = 1 : t < 0 && (e = -1), e;
  }(m)) {
    case 1:
      {
        var _t62 = h - c;
        0 != _t62 && (l = m * ((d - _) / _t62), l += _);
        break;
      }
    case -1:
      {
        var _t63 = u - c;
        0 != _t63 && (l = m * ((g - _) / _t63), l += _);
        break;
      }
    case 0:
      l = _;
  }
  return o ? l : -1 * l;
}
var Si;
!function (t) {
  t.CubismPhysics = ii, t.Options = si;
}(Si || (Si = {}));
var Ci = /*#__PURE__*/function () {
  function Ci(t) {
    (0,classCallCheck/* default */.A)(this, Ci);
    this._renderTextureCount = 0, this._clippingMaskBufferSize = 256, this._clippingContextListForMask = new e(), this._clippingContextListForDraw = new e(), this._channelColors = new e(), this._tmpBoundsOnModel = new m(), this._tmpMatrix = new c(), this._tmpMatrixForMask = new c(), this._tmpMatrixForDraw = new c(), this._clippingContexttConstructor = t;
    var i = new f();
    i.r = 1, i.g = 0, i.b = 0, i.a = 0, this._channelColors.pushBack(i), i = new f(), i.r = 0, i.g = 1, i.b = 0, i.a = 0, this._channelColors.pushBack(i), i = new f(), i.r = 0, i.g = 0, i.b = 1, i.a = 0, this._channelColors.pushBack(i), i = new f(), i.r = 0, i.g = 0, i.b = 0, i.a = 1, this._channelColors.pushBack(i);
  }
  (0,createClass/* default */.A)(Ci, [{
    key: "release",
    value: function release() {
      for (var _t64 = 0; _t64 < this._clippingContextListForMask.getSize(); _t64++) this._clippingContextListForMask.at(_t64) && (this._clippingContextListForMask.at(_t64).release(), this._clippingContextListForMask.set(_t64, void 0)), this._clippingContextListForMask.set(_t64, null);
      this._clippingContextListForMask = null;
      for (var _t65 = 0; _t65 < this._clippingContextListForDraw.getSize(); _t65++) this._clippingContextListForDraw.set(_t65, null);
      this._clippingContextListForDraw = null;
      for (var _t66 = 0; _t66 < this._channelColors.getSize(); _t66++) this._channelColors.set(_t66, null);
      this._channelColors = null, null != this._clearedFrameBufferFlags && this._clearedFrameBufferFlags.clear(), this._clearedFrameBufferFlags = null;
    }
  }, {
    key: "initialize",
    value: function initialize(t, i) {
      i % 1 != 0 && (v('The number of render textures must be specified as an integer. The decimal point is rounded down and corrected to an integer.'), i = ~~i), i < 1 && v('The number of render textures must be an integer greater than or equal to 1. Set the number of render textures to 1.'), this._renderTextureCount = i < 1 ? 1 : i, this._clearedFrameBufferFlags = new e(this._renderTextureCount);
      for (var _e82 = 0; _e82 < t.getDrawableCount(); _e82++) {
        if (t.getDrawableMaskCounts()[_e82] <= 0) {
          this._clippingContextListForDraw.pushBack(null);
          continue;
        }
        var _i45 = this.findSameClip(t.getDrawableMasks()[_e82], t.getDrawableMaskCounts()[_e82]);
        null == _i45 && (_i45 = new this._clippingContexttConstructor(this, t.getDrawableMasks()[_e82], t.getDrawableMaskCounts()[_e82]), this._clippingContextListForMask.pushBack(_i45)), _i45.addClippedDrawable(_e82), this._clippingContextListForDraw.pushBack(_i45);
      }
    }
  }, {
    key: "findSameClip",
    value: function findSameClip(t, e) {
      for (var _i46 = 0; _i46 < this._clippingContextListForMask.getSize(); _i46++) {
        var _s39 = this._clippingContextListForMask.at(_i46),
          _r14 = _s39._clippingIdCount;
        if (_r14 != e) continue;
        var _a9 = 0;
        for (var _e83 = 0; _e83 < _r14; _e83++) {
          var _i47 = _s39._clippingIdList[_e83];
          for (var _e84 = 0; _e84 < _r14; _e84++) {
            if (t[_e84] == _i47) {
              _a9++;
              break;
            }
          }
        }
        if (_a9 == _r14) return _s39;
      }
      return null;
    }
  }, {
    key: "setupMatrixForHighPrecision",
    value: function setupMatrixForHighPrecision(t, e) {
      var i = 0;
      for (var _e85 = 0; _e85 < this._clippingContextListForMask.getSize(); _e85++) {
        var _s40 = this._clippingContextListForMask.at(_e85);
        this.calcClippedDrawTotalBounds(t, _s40), _s40._isUsing && i++;
      }
      if (i > 0) {
        if (this.setupLayoutBounds(0), this._clearedFrameBufferFlags.getSize() != this._renderTextureCount) {
          this._clearedFrameBufferFlags.clear();
          for (var _t67 = 0; _t67 < this._renderTextureCount; _t67++) this._clearedFrameBufferFlags.pushBack(!1);
        } else {
          for (var _t68 = 0; _t68 < this._renderTextureCount; _t68++) this._clearedFrameBufferFlags.set(_t68, !1);
        }
        for (var _i48 = 0; _i48 < this._clippingContextListForMask.getSize(); _i48++) {
          var _s41 = this._clippingContextListForMask.at(_i48),
            _r15 = _s41._allClippedDrawRect,
            _a10 = _s41._layoutBounds,
            _n10 = .05;
          var _o5 = 0,
            _l4 = 0;
          var _h3 = t.getPixelsPerUnit(),
            _u3 = _s41.getClippingManager().getClippingMaskBufferSize(),
            _g2 = _a10.width * _u3,
            _d2 = _a10.height * _u3;
          this._tmpBoundsOnModel.setRect(_r15), this._tmpBoundsOnModel.width * _h3 > _g2 ? (this._tmpBoundsOnModel.expand(_r15.width * _n10, 0), _o5 = _a10.width / this._tmpBoundsOnModel.width) : _o5 = _h3 / _g2, this._tmpBoundsOnModel.height * _h3 > _d2 ? (this._tmpBoundsOnModel.expand(0, _r15.height * _n10), _l4 = _a10.height / this._tmpBoundsOnModel.height) : _l4 = _h3 / _d2, this.createMatrixForMask(e, _a10, _o5, _l4), _s41._matrixForMask.setMatrix(this._tmpMatrixForMask.getArray()), _s41._matrixForDraw.setMatrix(this._tmpMatrixForDraw.getArray());
        }
      }
    }
  }, {
    key: "createMatrixForMask",
    value: function createMatrixForMask(t, e, i, s) {
      this._tmpMatrix.loadIdentity(), this._tmpMatrix.translateRelative(-1, -1), this._tmpMatrix.scaleRelative(2, 2), this._tmpMatrix.translateRelative(e.x, e.y), this._tmpMatrix.scaleRelative(i, s), this._tmpMatrix.translateRelative(-this._tmpBoundsOnModel.x, -this._tmpBoundsOnModel.y), this._tmpMatrixForMask.setMatrix(this._tmpMatrix.getArray()), this._tmpMatrix.loadIdentity(), this._tmpMatrix.translateRelative(e.x, e.y * (t ? -1 : 1)), this._tmpMatrix.scaleRelative(i, s * (t ? -1 : 1)), this._tmpMatrix.translateRelative(-this._tmpBoundsOnModel.x, -this._tmpBoundsOnModel.y), this._tmpMatrixForDraw.setMatrix(this._tmpMatrix.getArray());
    }
  }, {
    key: "setupLayoutBounds",
    value: function setupLayoutBounds(t) {
      var e = this._renderTextureCount <= 1 ? 36 : 32 * this._renderTextureCount;
      if (t <= 0 || t > e) {
        t > e && b('not supported mask count : {0}\n[Details] render texture count : {1}, mask count : {2}', t - e, this._renderTextureCount, t);
        for (var _t69 = 0; _t69 < this._clippingContextListForMask.getSize(); _t69++) {
          var _e86 = this._clippingContextListForMask.at(_t69);
          _e86._layoutChannelIndex = 0, _e86._layoutBounds.x = 0, _e86._layoutBounds.y = 0, _e86._layoutBounds.width = 1, _e86._layoutBounds.height = 1, _e86._bufferIndex = 0;
        }
        return;
      }
      var i = this._renderTextureCount <= 1 ? 9 : 8;
      var s = t / this._renderTextureCount;
      var r = t % this._renderTextureCount;
      s = Math.ceil(s);
      var a = s / 4;
      var n = s % 4;
      a = ~~a;
      var o = 0;
      for (var _s42 = 0; _s42 < this._renderTextureCount; _s42++) {
        for (var _l5 = 0; _l5 < 4; _l5++) {
          var _h4 = a + (_l5 < n ? 1 : 0);
          if (_l5 == n + (a < 1 ? -1 : 0) && r > 0 && (_h4 -= _s42 < r ? 0 : 1), 0 == _h4) {} else if (1 == _h4) {
            var _t70 = this._clippingContextListForMask.at(o++);
            _t70._layoutChannelIndex = _l5, _t70._layoutBounds.x = 0, _t70._layoutBounds.y = 0, _t70._layoutBounds.width = 1, _t70._layoutBounds.height = 1, _t70._bufferIndex = _s42;
          } else if (2 == _h4) {
            for (var _t71 = 0; _t71 < _h4; _t71++) {
              var _e87 = _t71 % 2;
              _e87 = ~~_e87;
              var _i49 = this._clippingContextListForMask.at(o++);
              _i49._layoutChannelIndex = _l5, _i49._layoutBounds.x = .5 * _e87, _i49._layoutBounds.y = 0, _i49._layoutBounds.width = .5, _i49._layoutBounds.height = 1, _i49._bufferIndex = _s42;
            }
          } else if (_h4 <= 4) {
            for (var _t72 = 0; _t72 < _h4; _t72++) {
              var _e88 = _t72 % 2,
                _i50 = _t72 / 2;
              _e88 = ~~_e88, _i50 = ~~_i50;
              var _r16 = this._clippingContextListForMask.at(o++);
              _r16._layoutChannelIndex = _l5, _r16._layoutBounds.x = .5 * _e88, _r16._layoutBounds.y = .5 * _i50, _r16._layoutBounds.width = .5, _r16._layoutBounds.height = .5, _r16._bufferIndex = _s42;
            }
          } else if (_h4 <= i) {
            for (var _t73 = 0; _t73 < _h4; _t73++) {
              var _e89 = _t73 % 3,
                _i51 = _t73 / 3;
              _e89 = ~~_e89, _i51 = ~~_i51;
              var _r17 = this._clippingContextListForMask.at(o++);
              _r17._layoutChannelIndex = _l5, _r17._layoutBounds.x = _e89 / 3, _r17._layoutBounds.y = _i51 / 3, _r17._layoutBounds.width = 1 / 3, _r17._layoutBounds.height = 1 / 3, _r17._bufferIndex = _s42;
            }
          } else {
            b('not supported mask count : {0}\n[Details] render texture count : {1}, mask count : {2}', t - e, this._renderTextureCount, t);
            for (var _t74 = 0; _t74 < _h4; _t74++) {
              var _t75 = this._clippingContextListForMask.at(o++);
              _t75._layoutChannelIndex = 0, _t75._layoutBounds.x = 0, _t75._layoutBounds.y = 0, _t75._layoutBounds.width = 1, _t75._layoutBounds.height = 1, _t75._bufferIndex = 0;
            }
          }
        }
      }
    }
  }, {
    key: "calcClippedDrawTotalBounds",
    value: function calcClippedDrawTotalBounds(t, e) {
      var i = Number.MAX_VALUE,
        s = Number.MAX_VALUE,
        r = Number.MIN_VALUE,
        a = Number.MIN_VALUE;
      var n = e._clippedDrawableIndexList.length;
      for (var _o6 = 0; _o6 < n; _o6++) {
        var _n11 = e._clippedDrawableIndexList[_o6],
          _l6 = t.getDrawableVertexCount(_n11),
          _h5 = t.getDrawableVertices(_n11);
        var _u4 = Number.MAX_VALUE,
          _g3 = Number.MAX_VALUE,
          _d3 = -Number.MAX_VALUE,
          _3 = -Number.MAX_VALUE;
        var _c3 = _l6 * W.vertexStep;
        for (var _t76 = W.vertexOffset; _t76 < _c3; _t76 += W.vertexStep) {
          var _e90 = _h5[_t76],
            _i52 = _h5[_t76 + 1];
          _e90 < _u4 && (_u4 = _e90), _e90 > _d3 && (_d3 = _e90), _i52 < _g3 && (_g3 = _i52), _i52 > _3 && (_3 = _i52);
        }
        if (_u4 != Number.MAX_VALUE) {
          if (_u4 < i && (i = _u4), _g3 < s && (s = _g3), _d3 > r && (r = _d3), _3 > a && (a = _3), i == Number.MAX_VALUE) {
            e._allClippedDrawRect.x = 0, e._allClippedDrawRect.y = 0, e._allClippedDrawRect.width = 0, e._allClippedDrawRect.height = 0, e._isUsing = !1;
          } else {
            e._isUsing = !0;
            var _t77 = r - i,
              _n12 = a - s;
            e._allClippedDrawRect.x = i, e._allClippedDrawRect.y = s, e._allClippedDrawRect.width = _t77, e._allClippedDrawRect.height = _n12;
          }
        }
      }
    }
  }, {
    key: "getClippingContextListForDraw",
    value: function getClippingContextListForDraw() {
      return this._clippingContextListForDraw;
    }
  }, {
    key: "getClippingMaskBufferSize",
    value: function getClippingMaskBufferSize() {
      return this._clippingMaskBufferSize;
    }
  }, {
    key: "getRenderTextureCount",
    value: function getRenderTextureCount() {
      return this._renderTextureCount;
    }
  }, {
    key: "getChannelFlagAsColor",
    value: function getChannelFlagAsColor(t) {
      return this._channelColors.at(t);
    }
  }, {
    key: "setClippingMaskBufferSize",
    value: function setClippingMaskBufferSize(t) {
      this._clippingMaskBufferSize = t;
    }
  }]);
  return Ci;
}();
var xi;
var Mi = /*#__PURE__*/function () {
  function Mi() {
    (0,classCallCheck/* default */.A)(this, Mi);
    this._shaderSets = new e();
  }
  (0,createClass/* default */.A)(Mi, [{
    key: "release",
    value: function release() {
      this.releaseShaderProgram();
    }
  }, {
    key: "setupShaderProgramForDraw",
    value: function setupShaderProgramForDraw(t, e, i) {
      var s, r, a, n;
      t.isPremultipliedAlpha() || b('NoPremultipliedAlpha is not allowed'), 0 == this._shaderSets.getSize() && this.generateShaders();
      var o = null != t.getClippingContextBufferForDraw(),
        l = e.getDrawableInvertedMaskBit(i),
        u = o ? l ? 2 : 1 : 0;
      var g;
      switch (e.getDrawableBlendMode(i)) {
        case h.CubismBlendMode_Normal:
        default:
          g = this._shaderSets.at(Pi.ShaderNames_NormalPremultipliedAlpha + u), s = this.gl.ONE, r = this.gl.ONE_MINUS_SRC_ALPHA, a = this.gl.ONE, n = this.gl.ONE_MINUS_SRC_ALPHA;
          break;
        case h.CubismBlendMode_Additive:
          g = this._shaderSets.at(Pi.ShaderNames_AddPremultipliedAlpha + u), s = this.gl.ONE, r = this.gl.ONE, a = this.gl.ZERO, n = this.gl.ONE;
          break;
        case h.CubismBlendMode_Multiplicative:
          g = this._shaderSets.at(Pi.ShaderNames_MultPremultipliedAlpha + u), s = this.gl.DST_COLOR, r = this.gl.ONE_MINUS_SRC_ALPHA, a = this.gl.ZERO, n = this.gl.ONE;
      }
      this.gl.useProgram(g.shaderProgram), null == t._bufferData.vertex && (t._bufferData.vertex = this.gl.createBuffer()), this.gl.bindBuffer(this.gl.ARRAY_BUFFER, t._bufferData.vertex);
      var d = e.getDrawableVertices(i);
      this.gl.bufferData(this.gl.ARRAY_BUFFER, d, this.gl.DYNAMIC_DRAW), this.gl.enableVertexAttribArray(g.attributePositionLocation), this.gl.vertexAttribPointer(g.attributePositionLocation, 2, this.gl.FLOAT, !1, 0, 0), null == t._bufferData.uv && (t._bufferData.uv = this.gl.createBuffer()), this.gl.bindBuffer(this.gl.ARRAY_BUFFER, t._bufferData.uv);
      var _ = e.getDrawableVertexUvs(i);
      if (this.gl.bufferData(this.gl.ARRAY_BUFFER, _, this.gl.DYNAMIC_DRAW), this.gl.enableVertexAttribArray(g.attributeTexCoordLocation), this.gl.vertexAttribPointer(g.attributeTexCoordLocation, 2, this.gl.FLOAT, !1, 0, 0), o) {
        this.gl.activeTexture(this.gl.TEXTURE1);
        var _e91 = t.getClippingContextBufferForDraw().getClippingManager().getColorBuffer().at(t.getClippingContextBufferForDraw()._bufferIndex);
        this.gl.bindTexture(this.gl.TEXTURE_2D, _e91), this.gl.uniform1i(g.samplerTexture1Location, 1), this.gl.uniformMatrix4fv(g.uniformClipMatrixLocation, !1, t.getClippingContextBufferForDraw()._matrixForDraw.getArray());
        var _i53 = t.getClippingContextBufferForDraw()._layoutChannelIndex,
          _s43 = t.getClippingContextBufferForDraw().getClippingManager().getChannelFlagAsColor(_i53);
        this.gl.uniform4f(g.uniformChannelFlagLocation, _s43.r, _s43.g, _s43.b, _s43.a);
      }
      var c = e.getDrawableTextureIndex(i),
        m = t.getBindedTextures().getValue(c);
      this.gl.activeTexture(this.gl.TEXTURE0), this.gl.bindTexture(this.gl.TEXTURE_2D, m), this.gl.uniform1i(g.samplerTexture0Location, 0);
      var p = t.getMvpMatrix();
      this.gl.uniformMatrix4fv(g.uniformMatrixLocation, !1, p.getArray());
      var f = t.getModelColorWithOpacity(e.getDrawableOpacity(i)),
        y = e.getMultiplyColor(i),
        S = e.getScreenColor(i);
      this.gl.uniform4f(g.uniformBaseColorLocation, f.r, f.g, f.b, f.a), this.gl.uniform4f(g.uniformMultiplyColorLocation, y.r, y.g, y.b, y.a), this.gl.uniform4f(g.uniformScreenColorLocation, S.r, S.g, S.b, S.a), null == t._bufferData.index && (t._bufferData.index = this.gl.createBuffer());
      var C = e.getDrawableVertexIndices(i);
      this.gl.bindBuffer(this.gl.ELEMENT_ARRAY_BUFFER, t._bufferData.index), this.gl.bufferData(this.gl.ELEMENT_ARRAY_BUFFER, C, this.gl.DYNAMIC_DRAW), this.gl.blendFuncSeparate(s, r, a, n);
    }
  }, {
    key: "setupShaderProgramForMask",
    value: function setupShaderProgramForMask(t, e, i) {
      t.isPremultipliedAlpha() || b('NoPremultipliedAlpha is not allowed'), 0 == this._shaderSets.getSize() && this.generateShaders();
      var s = this._shaderSets.at(Pi.ShaderNames_SetupMask);
      this.gl.useProgram(s.shaderProgram), null == t._bufferData.vertex && (t._bufferData.vertex = this.gl.createBuffer()), this.gl.bindBuffer(this.gl.ARRAY_BUFFER, t._bufferData.vertex);
      var r = e.getDrawableVertices(i);
      this.gl.bufferData(this.gl.ARRAY_BUFFER, r, this.gl.DYNAMIC_DRAW), this.gl.enableVertexAttribArray(s.attributePositionLocation), this.gl.vertexAttribPointer(s.attributePositionLocation, 2, this.gl.FLOAT, !1, 0, 0), null == t._bufferData.uv && (t._bufferData.uv = this.gl.createBuffer()), this.gl.bindBuffer(this.gl.ARRAY_BUFFER, t._bufferData.uv);
      var a = e.getDrawableTextureIndex(i),
        n = t.getBindedTextures().getValue(a);
      this.gl.activeTexture(this.gl.TEXTURE0), this.gl.bindTexture(this.gl.TEXTURE_2D, n), this.gl.uniform1i(s.samplerTexture0Location, 0), null == t._bufferData.uv && (t._bufferData.uv = this.gl.createBuffer()), this.gl.bindBuffer(this.gl.ARRAY_BUFFER, t._bufferData.uv);
      var o = e.getDrawableVertexUvs(i);
      this.gl.bufferData(this.gl.ARRAY_BUFFER, o, this.gl.DYNAMIC_DRAW), this.gl.enableVertexAttribArray(s.attributeTexCoordLocation), this.gl.vertexAttribPointer(s.attributeTexCoordLocation, 2, this.gl.FLOAT, !1, 0, 0), t.getClippingContextBufferForMask();
      var l = t.getClippingContextBufferForMask()._layoutChannelIndex,
        h = t.getClippingContextBufferForMask().getClippingManager().getChannelFlagAsColor(l);
      this.gl.uniform4f(s.uniformChannelFlagLocation, h.r, h.g, h.b, h.a), this.gl.uniformMatrix4fv(s.uniformClipMatrixLocation, !1, t.getClippingContextBufferForMask()._matrixForMask.getArray());
      var u = t.getClippingContextBufferForMask()._layoutBounds;
      this.gl.uniform4f(s.uniformBaseColorLocation, 2 * u.x - 1, 2 * u.y - 1, 2 * u.getRight() - 1, 2 * u.getBottom() - 1);
      var g = e.getMultiplyColor(i),
        d = e.getScreenColor(i);
      this.gl.uniform4f(s.uniformMultiplyColorLocation, g.r, g.g, g.b, g.a), this.gl.uniform4f(s.uniformScreenColorLocation, d.r, d.g, d.b, d.a);
      var _ = this.gl.ZERO,
        c = this.gl.ONE_MINUS_SRC_COLOR,
        m = this.gl.ZERO,
        p = this.gl.ONE_MINUS_SRC_ALPHA;
      null == t._bufferData.index && (t._bufferData.index = this.gl.createBuffer());
      var f = e.getDrawableVertexIndices(i);
      this.gl.bindBuffer(this.gl.ELEMENT_ARRAY_BUFFER, t._bufferData.index), this.gl.bufferData(this.gl.ELEMENT_ARRAY_BUFFER, f, this.gl.DYNAMIC_DRAW), this.gl.blendFuncSeparate(_, c, m, p);
    }
  }, {
    key: "releaseShaderProgram",
    value: function releaseShaderProgram() {
      for (var _t78 = 0; _t78 < this._shaderSets.getSize(); _t78++) this.gl.deleteProgram(this._shaderSets.at(_t78).shaderProgram), this._shaderSets.at(_t78).shaderProgram = 0, this._shaderSets.set(_t78, void 0), this._shaderSets.set(_t78, null);
    }
  }, {
    key: "generateShaders",
    value: function generateShaders() {
      for (var _t79 = 0; _t79 < 10; _t79++) this._shaderSets.pushBack(new bi());
      this._shaderSets.at(0).shaderProgram = this.loadShaderProgram(Bi, wi), this._shaderSets.at(1).shaderProgram = this.loadShaderProgram(Fi, Vi), this._shaderSets.at(2).shaderProgram = this.loadShaderProgram(Ii, Ei), this._shaderSets.at(3).shaderProgram = this.loadShaderProgram(Ii, Ri), this._shaderSets.at(4).shaderProgram = this._shaderSets.at(1).shaderProgram, this._shaderSets.at(5).shaderProgram = this._shaderSets.at(2).shaderProgram, this._shaderSets.at(6).shaderProgram = this._shaderSets.at(3).shaderProgram, this._shaderSets.at(7).shaderProgram = this._shaderSets.at(1).shaderProgram, this._shaderSets.at(8).shaderProgram = this._shaderSets.at(2).shaderProgram, this._shaderSets.at(9).shaderProgram = this._shaderSets.at(3).shaderProgram, this._shaderSets.at(0).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(0).shaderProgram, 'a_position'), this._shaderSets.at(0).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(0).shaderProgram, 'a_texCoord'), this._shaderSets.at(0).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(0).shaderProgram, 's_texture0'), this._shaderSets.at(0).uniformClipMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(0).shaderProgram, 'u_clipMatrix'), this._shaderSets.at(0).uniformChannelFlagLocation = this.gl.getUniformLocation(this._shaderSets.at(0).shaderProgram, 'u_channelFlag'), this._shaderSets.at(0).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(0).shaderProgram, 'u_baseColor'), this._shaderSets.at(0).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(0).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(0).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(0).shaderProgram, 'u_screenColor'), this._shaderSets.at(1).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(1).shaderProgram, 'a_position'), this._shaderSets.at(1).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(1).shaderProgram, 'a_texCoord'), this._shaderSets.at(1).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(1).shaderProgram, 's_texture0'), this._shaderSets.at(1).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(1).shaderProgram, 'u_matrix'), this._shaderSets.at(1).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(1).shaderProgram, 'u_baseColor'), this._shaderSets.at(1).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(1).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(1).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(1).shaderProgram, 'u_screenColor'), this._shaderSets.at(2).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(2).shaderProgram, 'a_position'), this._shaderSets.at(2).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(2).shaderProgram, 'a_texCoord'), this._shaderSets.at(2).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(2).shaderProgram, 's_texture0'), this._shaderSets.at(2).samplerTexture1Location = this.gl.getUniformLocation(this._shaderSets.at(2).shaderProgram, 's_texture1'), this._shaderSets.at(2).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(2).shaderProgram, 'u_matrix'), this._shaderSets.at(2).uniformClipMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(2).shaderProgram, 'u_clipMatrix'), this._shaderSets.at(2).uniformChannelFlagLocation = this.gl.getUniformLocation(this._shaderSets.at(2).shaderProgram, 'u_channelFlag'), this._shaderSets.at(2).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(2).shaderProgram, 'u_baseColor'), this._shaderSets.at(2).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(2).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(2).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(2).shaderProgram, 'u_screenColor'), this._shaderSets.at(3).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(3).shaderProgram, 'a_position'), this._shaderSets.at(3).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(3).shaderProgram, 'a_texCoord'), this._shaderSets.at(3).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(3).shaderProgram, 's_texture0'), this._shaderSets.at(3).samplerTexture1Location = this.gl.getUniformLocation(this._shaderSets.at(3).shaderProgram, 's_texture1'), this._shaderSets.at(3).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(3).shaderProgram, 'u_matrix'), this._shaderSets.at(3).uniformClipMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(3).shaderProgram, 'u_clipMatrix'), this._shaderSets.at(3).uniformChannelFlagLocation = this.gl.getUniformLocation(this._shaderSets.at(3).shaderProgram, 'u_channelFlag'), this._shaderSets.at(3).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(3).shaderProgram, 'u_baseColor'), this._shaderSets.at(3).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(3).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(3).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(3).shaderProgram, 'u_screenColor'), this._shaderSets.at(4).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(4).shaderProgram, 'a_position'), this._shaderSets.at(4).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(4).shaderProgram, 'a_texCoord'), this._shaderSets.at(4).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(4).shaderProgram, 's_texture0'), this._shaderSets.at(4).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(4).shaderProgram, 'u_matrix'), this._shaderSets.at(4).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(4).shaderProgram, 'u_baseColor'), this._shaderSets.at(4).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(4).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(4).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(4).shaderProgram, 'u_screenColor'), this._shaderSets.at(5).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(5).shaderProgram, 'a_position'), this._shaderSets.at(5).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(5).shaderProgram, 'a_texCoord'), this._shaderSets.at(5).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(5).shaderProgram, 's_texture0'), this._shaderSets.at(5).samplerTexture1Location = this.gl.getUniformLocation(this._shaderSets.at(5).shaderProgram, 's_texture1'), this._shaderSets.at(5).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(5).shaderProgram, 'u_matrix'), this._shaderSets.at(5).uniformClipMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(5).shaderProgram, 'u_clipMatrix'), this._shaderSets.at(5).uniformChannelFlagLocation = this.gl.getUniformLocation(this._shaderSets.at(5).shaderProgram, 'u_channelFlag'), this._shaderSets.at(5).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(5).shaderProgram, 'u_baseColor'), this._shaderSets.at(5).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(5).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(5).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(5).shaderProgram, 'u_screenColor'), this._shaderSets.at(6).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(6).shaderProgram, 'a_position'), this._shaderSets.at(6).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(6).shaderProgram, 'a_texCoord'), this._shaderSets.at(6).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(6).shaderProgram, 's_texture0'), this._shaderSets.at(6).samplerTexture1Location = this.gl.getUniformLocation(this._shaderSets.at(6).shaderProgram, 's_texture1'), this._shaderSets.at(6).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(6).shaderProgram, 'u_matrix'), this._shaderSets.at(6).uniformClipMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(6).shaderProgram, 'u_clipMatrix'), this._shaderSets.at(6).uniformChannelFlagLocation = this.gl.getUniformLocation(this._shaderSets.at(6).shaderProgram, 'u_channelFlag'), this._shaderSets.at(6).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(6).shaderProgram, 'u_baseColor'), this._shaderSets.at(6).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(6).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(6).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(6).shaderProgram, 'u_screenColor'), this._shaderSets.at(7).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(7).shaderProgram, 'a_position'), this._shaderSets.at(7).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(7).shaderProgram, 'a_texCoord'), this._shaderSets.at(7).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(7).shaderProgram, 's_texture0'), this._shaderSets.at(7).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(7).shaderProgram, 'u_matrix'), this._shaderSets.at(7).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(7).shaderProgram, 'u_baseColor'), this._shaderSets.at(7).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(7).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(7).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(7).shaderProgram, 'u_screenColor'), this._shaderSets.at(8).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(8).shaderProgram, 'a_position'), this._shaderSets.at(8).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(8).shaderProgram, 'a_texCoord'), this._shaderSets.at(8).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(8).shaderProgram, 's_texture0'), this._shaderSets.at(8).samplerTexture1Location = this.gl.getUniformLocation(this._shaderSets.at(8).shaderProgram, 's_texture1'), this._shaderSets.at(8).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(8).shaderProgram, 'u_matrix'), this._shaderSets.at(8).uniformClipMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(8).shaderProgram, 'u_clipMatrix'), this._shaderSets.at(8).uniformChannelFlagLocation = this.gl.getUniformLocation(this._shaderSets.at(8).shaderProgram, 'u_channelFlag'), this._shaderSets.at(8).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(8).shaderProgram, 'u_baseColor'), this._shaderSets.at(8).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(8).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(8).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(8).shaderProgram, 'u_screenColor'), this._shaderSets.at(9).attributePositionLocation = this.gl.getAttribLocation(this._shaderSets.at(9).shaderProgram, 'a_position'), this._shaderSets.at(9).attributeTexCoordLocation = this.gl.getAttribLocation(this._shaderSets.at(9).shaderProgram, 'a_texCoord'), this._shaderSets.at(9).samplerTexture0Location = this.gl.getUniformLocation(this._shaderSets.at(9).shaderProgram, 's_texture0'), this._shaderSets.at(9).samplerTexture1Location = this.gl.getUniformLocation(this._shaderSets.at(9).shaderProgram, 's_texture1'), this._shaderSets.at(9).uniformMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(9).shaderProgram, 'u_matrix'), this._shaderSets.at(9).uniformClipMatrixLocation = this.gl.getUniformLocation(this._shaderSets.at(9).shaderProgram, 'u_clipMatrix'), this._shaderSets.at(9).uniformChannelFlagLocation = this.gl.getUniformLocation(this._shaderSets.at(9).shaderProgram, 'u_channelFlag'), this._shaderSets.at(9).uniformBaseColorLocation = this.gl.getUniformLocation(this._shaderSets.at(9).shaderProgram, 'u_baseColor'), this._shaderSets.at(9).uniformMultiplyColorLocation = this.gl.getUniformLocation(this._shaderSets.at(9).shaderProgram, 'u_multiplyColor'), this._shaderSets.at(9).uniformScreenColorLocation = this.gl.getUniformLocation(this._shaderSets.at(9).shaderProgram, 'u_screenColor');
    }
  }, {
    key: "loadShaderProgram",
    value: function loadShaderProgram(t, e) {
      var i = this.gl.createProgram(),
        s = this.compileShaderSource(this.gl.VERTEX_SHADER, t);
      if (!s) return b('Vertex shader compile error!'), 0;
      var r = this.compileShaderSource(this.gl.FRAGMENT_SHADER, e);
      if (!r) return b('Vertex shader compile error!'), 0;
      this.gl.attachShader(i, s), this.gl.attachShader(i, r), this.gl.linkProgram(i);
      return this.gl.getProgramParameter(i, this.gl.LINK_STATUS) ? (this.gl.deleteShader(s), this.gl.deleteShader(r), i) : (b('Failed to link program: {0}', i), this.gl.deleteShader(s), s = 0, this.gl.deleteShader(r), r = 0, i && (this.gl.deleteProgram(i), i = 0), 0);
    }
  }, {
    key: "compileShaderSource",
    value: function compileShaderSource(t, e) {
      var i = e,
        s = this.gl.createShader(t);
      if (this.gl.shaderSource(s, i), this.gl.compileShader(s), !s) {
        var _t80 = this.gl.getShaderInfoLog(s);
        b('Shader compile log: {0} ', _t80);
      }
      return this.gl.getShaderParameter(s, this.gl.COMPILE_STATUS) ? s : (this.gl.deleteShader(s), null);
    }
  }, {
    key: "setGl",
    value: function setGl(t) {
      this.gl = t;
    }
  }]);
  return Mi;
}();
var vi = /*#__PURE__*/function () {
  function vi() {
    (0,classCallCheck/* default */.A)(this, vi);
    this._shaderMap = new I();
  }
  (0,createClass/* default */.A)(vi, [{
    key: "release",
    value: function release() {
      for (var _t81 = this._shaderMap.begin(); _t81.notEqual(this._shaderMap.end()); _t81.preIncrement()) _t81.ptr().second.release();
      this._shaderMap.clear();
    }
  }, {
    key: "getShader",
    value: function getShader(t) {
      return this._shaderMap.getValue(t);
    }
  }, {
    key: "setGlContext",
    value: function setGlContext(t) {
      if (!this._shaderMap.isExist(t)) {
        var _e92 = new Mi();
        _e92.setGl(t), this._shaderMap.setValue(t, _e92);
      }
    }
  }], [{
    key: "getInstance",
    value: function getInstance() {
      return null == xi && (xi = new vi()), xi;
    }
  }, {
    key: "deleteInstance",
    value: function deleteInstance() {
      xi && (xi.release(), xi = null);
    }
  }]);
  return vi;
}();
var bi = /*#__PURE__*/(0,createClass/* default */.A)(function bi() {
  (0,classCallCheck/* default */.A)(this, bi);
});
var Pi;
!function (t) {
  t[t.ShaderNames_SetupMask = 0] = 'ShaderNames_SetupMask', t[t.ShaderNames_NormalPremultipliedAlpha = 1] = 'ShaderNames_NormalPremultipliedAlpha', t[t.ShaderNames_NormalMaskedPremultipliedAlpha = 2] = 'ShaderNames_NormalMaskedPremultipliedAlpha', t[t.ShaderNames_NomralMaskedInvertedPremultipliedAlpha = 3] = 'ShaderNames_NomralMaskedInvertedPremultipliedAlpha', t[t.ShaderNames_AddPremultipliedAlpha = 4] = 'ShaderNames_AddPremultipliedAlpha', t[t.ShaderNames_AddMaskedPremultipliedAlpha = 5] = 'ShaderNames_AddMaskedPremultipliedAlpha', t[t.ShaderNames_AddMaskedPremultipliedAlphaInverted = 6] = 'ShaderNames_AddMaskedPremultipliedAlphaInverted', t[t.ShaderNames_MultPremultipliedAlpha = 7] = 'ShaderNames_MultPremultipliedAlpha', t[t.ShaderNames_MultMaskedPremultipliedAlpha = 8] = 'ShaderNames_MultMaskedPremultipliedAlpha', t[t.ShaderNames_MultMaskedPremultipliedAlphaInverted = 9] = 'ShaderNames_MultMaskedPremultipliedAlphaInverted';
}(Pi || (Pi = {}));
var Bi = 'attribute vec4     a_position;attribute vec2     a_texCoord;varying vec2       v_texCoord;varying vec4       v_myPos;uniform mat4       u_clipMatrix;void main(){   gl_Position = u_clipMatrix * a_position;   v_myPos = u_clipMatrix * a_position;   v_texCoord = a_texCoord;   v_texCoord.y = 1.0 - v_texCoord.y;}',
  wi = 'precision mediump float;varying vec2       v_texCoord;varying vec4       v_myPos;uniform vec4       u_baseColor;uniform vec4       u_channelFlag;uniform sampler2D  s_texture0;void main(){   float isInside =        step(u_baseColor.x, v_myPos.x/v_myPos.w)       * step(u_baseColor.y, v_myPos.y/v_myPos.w)       * step(v_myPos.x/v_myPos.w, u_baseColor.z)       * step(v_myPos.y/v_myPos.w, u_baseColor.w);   gl_FragColor = u_channelFlag * texture2D(s_texture0, v_texCoord).a * isInside;}',
  Fi = 'attribute vec4     a_position;attribute vec2     a_texCoord;varying vec2       v_texCoord;uniform mat4       u_matrix;void main(){   gl_Position = u_matrix * a_position;   v_texCoord = a_texCoord;   v_texCoord.y = 1.0 - v_texCoord.y;}',
  Ii = 'attribute vec4     a_position;attribute vec2     a_texCoord;varying vec2       v_texCoord;varying vec4       v_clipPos;uniform mat4       u_matrix;uniform mat4       u_clipMatrix;void main(){   gl_Position = u_matrix * a_position;   v_clipPos = u_clipMatrix * a_position;   v_texCoord = a_texCoord;   v_texCoord.y = 1.0 - v_texCoord.y;}',
  Vi = 'precision mediump float;varying vec2       v_texCoord;uniform vec4       u_baseColor;uniform sampler2D  s_texture0;uniform vec4       u_multiplyColor;uniform vec4       u_screenColor;void main(){   vec4 texColor = texture2D(s_texture0, v_texCoord);   texColor.rgb = texColor.rgb * u_multiplyColor.rgb;   texColor.rgb = (texColor.rgb + u_screenColor.rgb * texColor.a) - (texColor.rgb * u_screenColor.rgb);   vec4 color = texColor * u_baseColor;   gl_FragColor = vec4(color.rgb, color.a);}',
  Ei = 'precision mediump float;varying vec2       v_texCoord;varying vec4       v_clipPos;uniform vec4       u_baseColor;uniform vec4       u_channelFlag;uniform sampler2D  s_texture0;uniform sampler2D  s_texture1;uniform vec4       u_multiplyColor;uniform vec4       u_screenColor;void main(){   vec4 texColor = texture2D(s_texture0, v_texCoord);   texColor.rgb = texColor.rgb * u_multiplyColor.rgb;   texColor.rgb = (texColor.rgb + u_screenColor.rgb * texColor.a) - (texColor.rgb * u_screenColor.rgb);   vec4 col_formask = texColor * u_baseColor;   vec4 clipMask = (1.0 - texture2D(s_texture1, v_clipPos.xy / v_clipPos.w)) * u_channelFlag;   float maskVal = clipMask.r + clipMask.g + clipMask.b + clipMask.a;   col_formask = col_formask * maskVal;   gl_FragColor = col_formask;}',
  Ri = 'precision mediump float;varying vec2      v_texCoord;varying vec4      v_clipPos;uniform sampler2D s_texture0;uniform sampler2D s_texture1;uniform vec4      u_channelFlag;uniform vec4      u_baseColor;uniform vec4      u_multiplyColor;uniform vec4      u_screenColor;void main(){   vec4 texColor = texture2D(s_texture0, v_texCoord);   texColor.rgb = texColor.rgb * u_multiplyColor.rgb;   texColor.rgb = (texColor.rgb + u_screenColor.rgb * texColor.a) - (texColor.rgb * u_screenColor.rgb);   vec4 col_formask = texColor * u_baseColor;   vec4 clipMask = (1.0 - texture2D(s_texture1, v_clipPos.xy / v_clipPos.w)) * u_channelFlag;   float maskVal = clipMask.r + clipMask.g + clipMask.b + clipMask.a;   col_formask = col_formask * (1.0 - maskVal);   gl_FragColor = col_formask;}';
var Ti;
var Li, Di;
!function (t) {
  t.CubismShaderSet = bi, t.CubismShader_WebGL = Mi, t.CubismShaderManager_WebGL = vi, t.ShaderNames = Pi;
}(Ti || (Ti = {}));
var Ai = /*#__PURE__*/function (_Ci) {
  (0,inherits/* default */.A)(Ai, _Ci);
  function Ai() {
    (0,classCallCheck/* default */.A)(this, Ai);
    return (0,callSuper/* default */.A)(this, Ai, [ki]);
  }
  (0,createClass/* default */.A)(Ai, [{
    key: "getMaskRenderTexture",
    value: function getMaskRenderTexture() {
      if (this._maskTexture && null != this._maskTexture.textures) {
        this._maskTexture.frameNo = this._currentFrameNo;
      } else {
        null != this._maskRenderTextures && this._maskRenderTextures.clear(), this._maskRenderTextures = new e(), null != this._maskColorBuffers && this._maskColorBuffers.clear(), this._maskColorBuffers = new e();
        var _t82 = this._clippingMaskBufferSize;
        for (var _e93 = 0; _e93 < this._renderTextureCount; _e93++) this._maskColorBuffers.pushBack(this.gl.createTexture()), this.gl.bindTexture(this.gl.TEXTURE_2D, this._maskColorBuffers.at(_e93)), this.gl.texImage2D(this.gl.TEXTURE_2D, 0, this.gl.RGBA, _t82, _t82, 0, this.gl.RGBA, this.gl.UNSIGNED_BYTE, null), this.gl.texParameteri(this.gl.TEXTURE_2D, this.gl.TEXTURE_WRAP_S, this.gl.CLAMP_TO_EDGE), this.gl.texParameteri(this.gl.TEXTURE_2D, this.gl.TEXTURE_WRAP_T, this.gl.CLAMP_TO_EDGE), this.gl.texParameteri(this.gl.TEXTURE_2D, this.gl.TEXTURE_MIN_FILTER, this.gl.LINEAR), this.gl.texParameteri(this.gl.TEXTURE_2D, this.gl.TEXTURE_MAG_FILTER, this.gl.LINEAR), this.gl.bindTexture(this.gl.TEXTURE_2D, null), this._maskRenderTextures.pushBack(this.gl.createFramebuffer()), this.gl.bindFramebuffer(this.gl.FRAMEBUFFER, this._maskRenderTextures.at(_e93)), this.gl.framebufferTexture2D(this.gl.FRAMEBUFFER, this.gl.COLOR_ATTACHMENT0, this.gl.TEXTURE_2D, this._maskColorBuffers.at(_e93), 0);
        this.gl.bindFramebuffer(this.gl.FRAMEBUFFER, Di), this._maskTexture = new Oi(this._currentFrameNo, this._maskRenderTextures);
      }
      return this._maskTexture.textures;
    }
  }, {
    key: "setGL",
    value: function setGL(t) {
      this.gl = t;
    }
  }, {
    key: "setupClippingContext",
    value: function setupClippingContext(t, i) {
      this._currentFrameNo++;
      var s = 0;
      for (var _e94 = 0; _e94 < this._clippingContextListForMask.getSize(); _e94++) {
        var _i54 = this._clippingContextListForMask.at(_e94);
        this.calcClippedDrawTotalBounds(t, _i54), _i54._isUsing && s++;
      }
      if (s > 0) {
        this.gl.viewport(0, 0, this._clippingMaskBufferSize, this._clippingMaskBufferSize), this._currentMaskRenderTexture = this.getMaskRenderTexture().at(0), i.preDraw(), this.setupLayoutBounds(s), this.gl.bindFramebuffer(this.gl.FRAMEBUFFER, this._currentMaskRenderTexture), this._clearedFrameBufferFlags.getSize() != this._renderTextureCount && (this._clearedFrameBufferFlags.clear(), this._clearedFrameBufferFlags = new e(this._renderTextureCount));
        for (var _t83 = 0; _t83 < this._clearedFrameBufferFlags.getSize(); _t83++) this._clearedFrameBufferFlags.set(_t83, !1);
        for (var _e95 = 0; _e95 < this._clippingContextListForMask.getSize(); _e95++) {
          var _s44 = this._clippingContextListForMask.at(_e95),
            _r18 = _s44._allClippedDrawRect,
            _a11 = _s44._layoutBounds,
            _n13 = .05;
          var _o7 = 0,
            _l7 = 0;
          var _h6 = this.getMaskRenderTexture().at(_s44._bufferIndex);
          this._currentMaskRenderTexture != _h6 && (this._currentMaskRenderTexture = _h6, i.preDraw(), this.gl.bindFramebuffer(this.gl.FRAMEBUFFER, this._currentMaskRenderTexture)), this._tmpBoundsOnModel.setRect(_r18), this._tmpBoundsOnModel.expand(_r18.width * _n13, _r18.height * _n13), _o7 = _a11.width / this._tmpBoundsOnModel.width, _l7 = _a11.height / this._tmpBoundsOnModel.height, this._tmpMatrix.loadIdentity(), this._tmpMatrix.translateRelative(-1, -1), this._tmpMatrix.scaleRelative(2, 2), this._tmpMatrix.translateRelative(_a11.x, _a11.y), this._tmpMatrix.scaleRelative(_o7, _l7), this._tmpMatrix.translateRelative(-this._tmpBoundsOnModel.x, -this._tmpBoundsOnModel.y), this._tmpMatrixForMask.setMatrix(this._tmpMatrix.getArray()), this._tmpMatrix.loadIdentity(), this._tmpMatrix.translateRelative(_a11.x, _a11.y), this._tmpMatrix.scaleRelative(_o7, _l7), this._tmpMatrix.translateRelative(-this._tmpBoundsOnModel.x, -this._tmpBoundsOnModel.y), this._tmpMatrixForDraw.setMatrix(this._tmpMatrix.getArray()), _s44._matrixForMask.setMatrix(this._tmpMatrixForMask.getArray()), _s44._matrixForDraw.setMatrix(this._tmpMatrixForDraw.getArray());
          var _u5 = _s44._clippingIdCount;
          for (var _e96 = 0; _e96 < _u5; _e96++) {
            var _r19 = _s44._clippingIdList[_e96];
            t.getDrawableDynamicFlagVertexPositionsDidChange(_r19) && (i.setIsCulling(0 != t.getDrawableCulling(_r19)), this._clearedFrameBufferFlags.at(_s44._bufferIndex) || (this.gl.clearColor(1, 1, 1, 1), this.gl.clear(this.gl.COLOR_BUFFER_BIT), this._clearedFrameBufferFlags.set(_s44._bufferIndex, !0)), i.setClippingContextBufferForMask(_s44), i.drawMeshWebGL(t, _r19));
          }
        }
        this.gl.bindFramebuffer(this.gl.FRAMEBUFFER, Di), i.setClippingContextBufferForMask(null), this.gl.viewport(Li[0], Li[1], Li[2], Li[3]);
      }
    }
  }, {
    key: "getColorBuffer",
    value: function getColorBuffer() {
      return this._maskColorBuffers;
    }
  }, {
    key: "getClippingMaskCount",
    value: function getClippingMaskCount() {
      return this._clippingContextListForMask.getSize();
    }
  }]);
  return Ai;
}(Ci);
var Oi = /*#__PURE__*/(0,createClass/* default */.A)(function Oi(t, e) {
  (0,classCallCheck/* default */.A)(this, Oi);
  this.frameNo = t, this.textures = e;
});
var ki = /*#__PURE__*/function (_y) {
  (0,inherits/* default */.A)(ki, _y);
  function ki(t, e, i) {
    var _this16;
    (0,classCallCheck/* default */.A)(this, ki);
    _this16 = (0,callSuper/* default */.A)(this, ki, [e, i]), _this16._owner = t;
    return _this16;
  }
  (0,createClass/* default */.A)(ki, [{
    key: "getClippingManager",
    value: function getClippingManager() {
      return this._owner;
    }
  }, {
    key: "setGl",
    value: function setGl(t) {
      this._owner.setGL(t);
    }
  }]);
  return ki;
}(y);
var Ni = /*#__PURE__*/function () {
  function Ni() {
    (0,classCallCheck/* default */.A)(this, Ni);
    this._lastVertexAttribArrayEnabled = new Array(4), this._lastColorMask = new Array(4), this._lastBlending = new Array(4), this._lastViewport = new Array(4);
  }
  (0,createClass/* default */.A)(Ni, [{
    key: "setGlEnable",
    value: function setGlEnable(t, e) {
      e ? this.gl.enable(t) : this.gl.disable(t);
    }
  }, {
    key: "setGlEnableVertexAttribArray",
    value: function setGlEnableVertexAttribArray(t, e) {
      e ? this.gl.enableVertexAttribArray(t) : this.gl.disableVertexAttribArray(t);
    }
  }, {
    key: "save",
    value: function save() {
      null != this.gl ? (this._lastArrayBufferBinding = this.gl.getParameter(this.gl.ARRAY_BUFFER_BINDING), this._lastElementArrayBufferBinding = this.gl.getParameter(this.gl.ELEMENT_ARRAY_BUFFER_BINDING), this._lastProgram = this.gl.getParameter(this.gl.CURRENT_PROGRAM), this._lastActiveTexture = this.gl.getParameter(this.gl.ACTIVE_TEXTURE), this.gl.activeTexture(this.gl.TEXTURE1), this._lastTexture1Binding2D = this.gl.getParameter(this.gl.TEXTURE_BINDING_2D), this.gl.activeTexture(this.gl.TEXTURE0), this._lastTexture0Binding2D = this.gl.getParameter(this.gl.TEXTURE_BINDING_2D), this._lastVertexAttribArrayEnabled[0] = this.gl.getVertexAttrib(0, this.gl.VERTEX_ATTRIB_ARRAY_ENABLED), this._lastVertexAttribArrayEnabled[1] = this.gl.getVertexAttrib(1, this.gl.VERTEX_ATTRIB_ARRAY_ENABLED), this._lastVertexAttribArrayEnabled[2] = this.gl.getVertexAttrib(2, this.gl.VERTEX_ATTRIB_ARRAY_ENABLED), this._lastVertexAttribArrayEnabled[3] = this.gl.getVertexAttrib(3, this.gl.VERTEX_ATTRIB_ARRAY_ENABLED), this._lastScissorTest = this.gl.isEnabled(this.gl.SCISSOR_TEST), this._lastStencilTest = this.gl.isEnabled(this.gl.STENCIL_TEST), this._lastDepthTest = this.gl.isEnabled(this.gl.DEPTH_TEST), this._lastCullFace = this.gl.isEnabled(this.gl.CULL_FACE), this._lastBlend = this.gl.isEnabled(this.gl.BLEND), this._lastFrontFace = this.gl.getParameter(this.gl.FRONT_FACE), this._lastColorMask = this.gl.getParameter(this.gl.COLOR_WRITEMASK), this._lastBlending[0] = this.gl.getParameter(this.gl.BLEND_SRC_RGB), this._lastBlending[1] = this.gl.getParameter(this.gl.BLEND_DST_RGB), this._lastBlending[2] = this.gl.getParameter(this.gl.BLEND_SRC_ALPHA), this._lastBlending[3] = this.gl.getParameter(this.gl.BLEND_DST_ALPHA), this._lastFBO = this.gl.getParameter(this.gl.FRAMEBUFFER_BINDING), this._lastViewport = this.gl.getParameter(this.gl.VIEWPORT)) : b('\'gl\' is null. WebGLRenderingContext is required.\nPlease call \'CubimRenderer_WebGL.startUp\' function.');
    }
  }, {
    key: "restore",
    value: function restore() {
      null != this.gl ? (this.gl.useProgram(this._lastProgram), this.setGlEnableVertexAttribArray(0, this._lastVertexAttribArrayEnabled[0]), this.setGlEnableVertexAttribArray(1, this._lastVertexAttribArrayEnabled[1]), this.setGlEnableVertexAttribArray(2, this._lastVertexAttribArrayEnabled[2]), this.setGlEnableVertexAttribArray(3, this._lastVertexAttribArrayEnabled[3]), this.setGlEnable(this.gl.SCISSOR_TEST, this._lastScissorTest), this.setGlEnable(this.gl.STENCIL_TEST, this._lastStencilTest), this.setGlEnable(this.gl.DEPTH_TEST, this._lastDepthTest), this.setGlEnable(this.gl.CULL_FACE, this._lastCullFace), this.setGlEnable(this.gl.BLEND, this._lastBlend), this.gl.frontFace(this._lastFrontFace), this.gl.colorMask(this._lastColorMask[0], this._lastColorMask[1], this._lastColorMask[2], this._lastColorMask[3]), this.gl.bindBuffer(this.gl.ARRAY_BUFFER, this._lastArrayBufferBinding), this.gl.bindBuffer(this.gl.ELEMENT_ARRAY_BUFFER, this._lastElementArrayBufferBinding), this.gl.activeTexture(this.gl.TEXTURE1), this.gl.bindTexture(this.gl.TEXTURE_2D, this._lastTexture1Binding2D), this.gl.activeTexture(this.gl.TEXTURE0), this.gl.bindTexture(this.gl.TEXTURE_2D, this._lastTexture0Binding2D), this.gl.activeTexture(this._lastActiveTexture), this.gl.blendFuncSeparate(this._lastBlending[0], this._lastBlending[1], this._lastBlending[2], this._lastBlending[3])) : b('\'gl\' is null. WebGLRenderingContext is required.\nPlease call \'CubimRenderer_WebGL.startUp\' function.');
    }
  }, {
    key: "setGl",
    value: function setGl(t) {
      this.gl = t;
    }
  }]);
  return Ni;
}();
var zi = /*#__PURE__*/function (_p) {
  (0,inherits/* default */.A)(zi, _p);
  function zi() {
    var _this17;
    (0,classCallCheck/* default */.A)(this, zi);
    _this17 = (0,callSuper/* default */.A)(this, zi), _this17._clippingContextBufferForMask = null, _this17._clippingContextBufferForDraw = null, _this17._rendererProfile = new Ni(), _this17.firstDraw = !0, _this17._textures = new I(), _this17._sortedDrawableIndexList = new e(), _this17._bufferData = {
      vertex: WebGLBuffer = null,
      uv: WebGLBuffer = null,
      index: WebGLBuffer = null
    }, _this17._textures.prepareCapacity(32, !0);
    return _this17;
  }
  (0,createClass/* default */.A)(zi, [{
    key: "initialize",
    value: function initialize(t) {
      var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
      t.isUsingMasking() && (this._clippingManager = new Ai(), this._clippingManager.initialize(t, e)), this._sortedDrawableIndexList.resize(t.getDrawableCount(), 0), _get((0,getPrototypeOf/* default */.A)(zi.prototype), "initialize", this).call(this, t);
    }
  }, {
    key: "bindTexture",
    value: function bindTexture(t, e) {
      this._textures.setValue(t, e);
    }
  }, {
    key: "getBindedTextures",
    value: function getBindedTextures() {
      return this._textures;
    }
  }, {
    key: "setClippingMaskBufferSize",
    value: function setClippingMaskBufferSize(t) {
      if (!this._model.isUsingMasking()) return;
      var e = this._clippingManager.getRenderTextureCount();
      this._clippingManager.release(), this._clippingManager = void 0, this._clippingManager = null, this._clippingManager = new Ai(), this._clippingManager.setClippingMaskBufferSize(t), this._clippingManager.initialize(this.getModel(), e);
    }
  }, {
    key: "getClippingMaskBufferSize",
    value: function getClippingMaskBufferSize() {
      return this._model.isUsingMasking() ? this._clippingManager.getClippingMaskBufferSize() : -1;
    }
  }, {
    key: "getRenderTextureCount",
    value: function getRenderTextureCount() {
      return this._model.isUsingMasking() ? this._clippingManager.getRenderTextureCount() : -1;
    }
  }, {
    key: "release",
    value: function release() {
      this._clippingManager && (this._clippingManager.release(), this._clippingManager = void 0, this._clippingManager = null), null != this.gl && (this.gl.deleteBuffer(this._bufferData.vertex), this._bufferData.vertex = null, this.gl.deleteBuffer(this._bufferData.uv), this._bufferData.uv = null, this.gl.deleteBuffer(this._bufferData.index), this._bufferData.index = null, this._bufferData = null, this._textures = null);
    }
  }, {
    key: "doDrawModel",
    value: function doDrawModel() {
      if (null == this.gl) return void b('\'gl\' is null. WebGLRenderingContext is required.\nPlease call \'CubimRenderer_WebGL.startUp\' function.');
      null != this._clippingManager && (this.preDraw(), this.isUsingHighPrecisionMask() ? this._clippingManager.setupMatrixForHighPrecision(this.getModel(), !1) : this._clippingManager.setupClippingContext(this.getModel(), this)), this.preDraw();
      var t = this.getModel().getDrawableCount(),
        e = this.getModel().getDrawableRenderOrders();
      for (var _i55 = 0; _i55 < t; ++_i55) {
        var _t84 = e[_i55];
        this._sortedDrawableIndexList.set(_t84, _i55);
      }
      for (var _e97 = 0; _e97 < t; ++_e97) {
        var _t85 = this._sortedDrawableIndexList.at(_e97);
        if (!this.getModel().getDrawableDynamicFlagIsVisible(_t85)) continue;
        var _i56 = null != this._clippingManager ? this._clippingManager.getClippingContextListForDraw().at(_t85) : null;
        if (null != _i56 && this.isUsingHighPrecisionMask()) {
          _i56._isUsing && (this.gl.viewport(0, 0, this._clippingManager.getClippingMaskBufferSize(), this._clippingManager.getClippingMaskBufferSize()), this.preDraw(), this.gl.bindFramebuffer(this.gl.FRAMEBUFFER, _i56.getClippingManager().getMaskRenderTexture().at(_i56._bufferIndex)), this.gl.clearColor(1, 1, 1, 1), this.gl.clear(this.gl.COLOR_BUFFER_BIT));
          {
            var _t86 = _i56._clippingIdCount;
            for (var _e98 = 0; _e98 < _t86; _e98++) {
              var _t87 = _i56._clippingIdList[_e98];
              this._model.getDrawableDynamicFlagVertexPositionsDidChange(_t87) && (this.setIsCulling(0 != this._model.getDrawableCulling(_t87)), this.setClippingContextBufferForMask(_i56), this.drawMeshWebGL(this._model, _t87));
            }
          }
          this.gl.bindFramebuffer(this.gl.FRAMEBUFFER, Di), this.setClippingContextBufferForMask(null), this.gl.viewport(Li[0], Li[1], Li[2], Li[3]), this.preDraw();
        }
        this.setClippingContextBufferForDraw(_i56), this.setIsCulling(this.getModel().getDrawableCulling(_t85)), this.drawMeshWebGL(this._model, _t85);
      }
    }
  }, {
    key: "drawMeshWebGL",
    value: function drawMeshWebGL(t, e) {
      this.isCulling() ? this.gl.enable(this.gl.CULL_FACE) : this.gl.disable(this.gl.CULL_FACE), this.gl.frontFace(this.gl.CCW), this.isGeneratingMask() ? vi.getInstance().getShader(this.gl).setupShaderProgramForMask(this, t, e) : vi.getInstance().getShader(this.gl).setupShaderProgramForDraw(this, t, e);
      {
        var _i57 = t.getDrawableVertexIndexCount(e);
        this.gl.drawElements(this.gl.TRIANGLES, _i57, this.gl.UNSIGNED_SHORT, 0);
      }
      this.gl.useProgram(null), this.setClippingContextBufferForDraw(null), this.setClippingContextBufferForMask(null);
    }
  }, {
    key: "saveProfile",
    value: function saveProfile() {
      this._rendererProfile.save();
    }
  }, {
    key: "restoreProfile",
    value: function restoreProfile() {
      this._rendererProfile.restore();
    }
  }, {
    key: "setRenderState",
    value: function setRenderState(t, e) {
      Di = t, Li = e;
    }
  }, {
    key: "preDraw",
    value: function preDraw() {
      if (this.firstDraw && (this.firstDraw = !1), this.gl.disable(this.gl.SCISSOR_TEST), this.gl.disable(this.gl.STENCIL_TEST), this.gl.disable(this.gl.DEPTH_TEST), this.gl.frontFace(this.gl.CW), this.gl.enable(this.gl.BLEND), this.gl.colorMask(!0, !0, !0, !0), this.gl.bindBuffer(this.gl.ARRAY_BUFFER, null), this.gl.bindBuffer(this.gl.ELEMENT_ARRAY_BUFFER, null), this.getAnisotropy() > 0 && this._extension) for (var _t88 = 0; _t88 < this._textures.getSize(); ++_t88) this.gl.bindTexture(this.gl.TEXTURE_2D, this._textures.getValue(_t88)), this.gl.texParameterf(this.gl.TEXTURE_2D, this._extension.TEXTURE_MAX_ANISOTROPY_EXT, this.getAnisotropy());
    }
  }, {
    key: "setClippingContextBufferForMask",
    value: function setClippingContextBufferForMask(t) {
      this._clippingContextBufferForMask = t;
    }
  }, {
    key: "getClippingContextBufferForMask",
    value: function getClippingContextBufferForMask() {
      return this._clippingContextBufferForMask;
    }
  }, {
    key: "setClippingContextBufferForDraw",
    value: function setClippingContextBufferForDraw(t) {
      this._clippingContextBufferForDraw = t;
    }
  }, {
    key: "getClippingContextBufferForDraw",
    value: function getClippingContextBufferForDraw() {
      return this._clippingContextBufferForDraw;
    }
  }, {
    key: "isGeneratingMask",
    value: function isGeneratingMask() {
      return null != this.getClippingContextBufferForMask();
    }
  }, {
    key: "startUp",
    value: function startUp(t) {
      this.gl = t, this._clippingManager && this._clippingManager.setGL(t), vi.getInstance().setGlContext(t), this._rendererProfile.setGl(t), this._extension = this.gl.getExtension('EXT_texture_filter_anisotropic') || this.gl.getExtension('WEBKIT_EXT_texture_filter_anisotropic') || this.gl.getExtension('MOZ_EXT_texture_filter_anisotropic');
    }
  }], [{
    key: "doStaticRelease",
    value: function doStaticRelease() {
      vi.deleteInstance();
    }
  }]);
  return zi;
}(p);
var Ui, Gi, Xi;
p.staticRelease = function () {
  zi.doStaticRelease();
}, function (t) {
  t.CubismClippingContext = ki, t.CubismClippingManager_WebGL = Ai, t.CubismRenderTextureResource = Oi, t.CubismRenderer_WebGL = zi;
}(Ui || (Ui = {}));
var Yi = /*#__PURE__*/(0,createClass/* default */.A)(function Yi() {
  var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : !1;
  var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : !1;
  (0,classCallCheck/* default */.A)(this, Yi);
  this.isOverridden = t, this.isParameterRepeated = e;
});
var ji = /*#__PURE__*/function () {
  function ji() {
    var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : !1;
    var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : new f();
    (0,classCallCheck/* default */.A)(this, ji);
    this.isOverridden = t, this.color = e;
  }
  (0,createClass/* default */.A)(ji, [{
    key: "isOverwritten",
    get: function get() {
      return this.isOverridden;
    }
  }]);
  return ji;
}();
var Hi = /*#__PURE__*/function () {
  function Hi() {
    var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : !1;
    var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : new f();
    (0,classCallCheck/* default */.A)(this, Hi);
    this.isOverridden = t, this.color = e;
  }
  (0,createClass/* default */.A)(Hi, [{
    key: "isOverwritten",
    get: function get() {
      return this.isOverridden;
    }
  }]);
  return Hi;
}();
var qi = /*#__PURE__*/function () {
  function qi() {
    var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : !1;
    var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : !1;
    (0,classCallCheck/* default */.A)(this, qi);
    this.isOverridden = t, this.isCulling = e;
  }
  (0,createClass/* default */.A)(qi, [{
    key: "isOverwritten",
    get: function get() {
      return this.isOverridden;
    }
  }]);
  return qi;
}();
var Wi = /*#__PURE__*/function () {
  function Wi(t) {
    (0,classCallCheck/* default */.A)(this, Wi);
    this._model = t, this._parameterValues = null, this._parameterMaximumValues = null, this._parameterMinimumValues = null, this._partOpacities = null, this._savedParameters = new e(), this._parameterIds = new e(), this._drawableIds = new e(), this._partIds = new e(), this._isOverriddenParameterRepeat = !0, this._isOverriddenModelMultiplyColors = !1, this._isOverriddenModelScreenColors = !1, this._isOverriddenCullings = !1, this._modelOpacity = 1, this._userParameterRepeatDataList = new e(), this._userMultiplyColors = new e(), this._userScreenColors = new e(), this._userCullings = new e(), this._userPartMultiplyColors = new e(), this._userPartScreenColors = new e(), this._partChildDrawables = new e(), this._notExistPartId = new I(), this._notExistParameterId = new I(), this._notExistParameterValues = new I(), this._notExistPartOpacities = new I();
  }
  (0,createClass/* default */.A)(Wi, [{
    key: "update",
    value: function update() {
      this._model.update(), this._model.drawables.resetDynamicFlags();
    }
  }, {
    key: "getPixelsPerUnit",
    value: function getPixelsPerUnit() {
      return null == this._model ? 0 : this._model.canvasinfo.PixelsPerUnit;
    }
  }, {
    key: "getCanvasWidth",
    value: function getCanvasWidth() {
      return null == this._model ? 0 : this._model.canvasinfo.CanvasWidth / this._model.canvasinfo.PixelsPerUnit;
    }
  }, {
    key: "getCanvasHeight",
    value: function getCanvasHeight() {
      return null == this._model ? 0 : this._model.canvasinfo.CanvasHeight / this._model.canvasinfo.PixelsPerUnit;
    }
  }, {
    key: "saveParameters",
    value: function saveParameters() {
      var t = this._model.parameters.count,
        e = this._savedParameters.getSize();
      for (var _i58 = 0; _i58 < t; ++_i58) _i58 < e ? this._savedParameters.set(_i58, this._parameterValues[_i58]) : this._savedParameters.pushBack(this._parameterValues[_i58]);
    }
  }, {
    key: "getMultiplyColor",
    value: function getMultiplyColor(t) {
      if (this.getOverrideFlagForModelMultiplyColors() || this.getOverrideFlagForDrawableMultiplyColors(t)) return this._userMultiplyColors.at(t).color;
      return this.getDrawableMultiplyColor(t);
    }
  }, {
    key: "getScreenColor",
    value: function getScreenColor(t) {
      if (this.getOverrideFlagForModelScreenColors() || this.getOverrideFlagForDrawableScreenColors(t)) return this._userScreenColors.at(t).color;
      return this.getDrawableScreenColor(t);
    }
  }, {
    key: "setMultiplyColorByTextureColor",
    value: function setMultiplyColorByTextureColor(t, e) {
      this.setMultiplyColorByRGBA(t, e.r, e.g, e.b, e.a);
    }
  }, {
    key: "setMultiplyColorByRGBA",
    value: function setMultiplyColorByRGBA(t, e, i, s) {
      var r = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 1;
      this._userMultiplyColors.at(t).color.r = e, this._userMultiplyColors.at(t).color.g = i, this._userMultiplyColors.at(t).color.b = s, this._userMultiplyColors.at(t).color.a = r;
    }
  }, {
    key: "setScreenColorByTextureColor",
    value: function setScreenColorByTextureColor(t, e) {
      this.setScreenColorByRGBA(t, e.r, e.g, e.b, e.a);
    }
  }, {
    key: "setScreenColorByRGBA",
    value: function setScreenColorByRGBA(t, e, i, s) {
      var r = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 1;
      this._userScreenColors.at(t).color.r = e, this._userScreenColors.at(t).color.g = i, this._userScreenColors.at(t).color.b = s, this._userScreenColors.at(t).color.a = r;
    }
  }, {
    key: "getPartMultiplyColor",
    value: function getPartMultiplyColor(t) {
      return this._userPartMultiplyColors.at(t).color;
    }
  }, {
    key: "getPartScreenColor",
    value: function getPartScreenColor(t) {
      return this._userPartScreenColors.at(t).color;
    }
  }, {
    key: "setPartColor",
    value: function setPartColor(t, e, i, s, r, a, n) {
      if (a.at(t).color.r = e, a.at(t).color.g = i, a.at(t).color.b = s, a.at(t).color.a = r, a.at(t).isOverridden) {
        for (var _a12 = 0; _a12 < this._partChildDrawables.at(t).getSize(); ++_a12) {
          var _o8 = this._partChildDrawables.at(t).at(_a12);
          n.at(_o8).color.r = e, n.at(_o8).color.g = i, n.at(_o8).color.b = s, n.at(_o8).color.a = r;
        }
      }
    }
  }, {
    key: "setPartMultiplyColorByTextureColor",
    value: function setPartMultiplyColorByTextureColor(t, e) {
      this.setPartMultiplyColorByRGBA(t, e.r, e.g, e.b, e.a);
    }
  }, {
    key: "setPartMultiplyColorByRGBA",
    value: function setPartMultiplyColorByRGBA(t, e, i, s, r) {
      this.setPartColor(t, e, i, s, r, this._userPartMultiplyColors, this._userMultiplyColors);
    }
  }, {
    key: "setPartScreenColorByTextureColor",
    value: function setPartScreenColorByTextureColor(t, e) {
      this.setPartScreenColorByRGBA(t, e.r, e.g, e.b, e.a);
    }
  }, {
    key: "setPartScreenColorByRGBA",
    value: function setPartScreenColorByRGBA(t, e, i, s, r) {
      this.setPartColor(t, e, i, s, r, this._userPartScreenColors, this._userScreenColors);
    }
  }, {
    key: "getOverrideFlagForModelParameterRepeat",
    value: function getOverrideFlagForModelParameterRepeat() {
      return this._isOverriddenParameterRepeat;
    }
  }, {
    key: "setOverrideFlagForModelParameterRepeat",
    value: function setOverrideFlagForModelParameterRepeat(t) {
      this._isOverriddenParameterRepeat = t;
    }
  }, {
    key: "getOverrideFlagForParameterRepeat",
    value: function getOverrideFlagForParameterRepeat(t) {
      return this._userParameterRepeatDataList.at(t).isOverridden;
    }
  }, {
    key: "setOverrideFlagForParameterRepeat",
    value: function setOverrideFlagForParameterRepeat(t, e) {
      this._userParameterRepeatDataList.at(t).isOverridden = e;
    }
  }, {
    key: "getRepeatFlagForParameterRepeat",
    value: function getRepeatFlagForParameterRepeat(t) {
      return this._userParameterRepeatDataList.at(t).isParameterRepeated;
    }
  }, {
    key: "setRepeatFlagForParameterRepeat",
    value: function setRepeatFlagForParameterRepeat(t, e) {
      this._userParameterRepeatDataList.at(t).isParameterRepeated = e;
    }
  }, {
    key: "getOverwriteFlagForModelMultiplyColors",
    value: function getOverwriteFlagForModelMultiplyColors() {
      return v('getOverwriteFlagForModelMultiplyColors() is a deprecated function. Please use getOverrideFlagForModelMultiplyColors().'), this.getOverrideFlagForModelMultiplyColors();
    }
  }, {
    key: "getOverrideFlagForModelMultiplyColors",
    value: function getOverrideFlagForModelMultiplyColors() {
      return this._isOverriddenModelMultiplyColors;
    }
  }, {
    key: "getOverwriteFlagForModelScreenColors",
    value: function getOverwriteFlagForModelScreenColors() {
      return v('getOverwriteFlagForModelScreenColors() is a deprecated function. Please use getOverrideFlagForModelScreenColors().'), this.getOverrideFlagForModelScreenColors();
    }
  }, {
    key: "getOverrideFlagForModelScreenColors",
    value: function getOverrideFlagForModelScreenColors() {
      return this._isOverriddenModelScreenColors;
    }
  }, {
    key: "setOverwriteFlagForModelMultiplyColors",
    value: function setOverwriteFlagForModelMultiplyColors(t) {
      v('setOverwriteFlagForModelMultiplyColors(value: boolean) is a deprecated function. Please use setOverrideFlagForModelMultiplyColors(value: boolean).'), this.setOverrideFlagForModelMultiplyColors(t);
    }
  }, {
    key: "setOverrideFlagForModelMultiplyColors",
    value: function setOverrideFlagForModelMultiplyColors(t) {
      this._isOverriddenModelMultiplyColors = t;
    }
  }, {
    key: "setOverwriteFlagForModelScreenColors",
    value: function setOverwriteFlagForModelScreenColors(t) {
      v('setOverwriteFlagForModelScreenColors(value: boolean) is a deprecated function. Please use setOverrideFlagForModelScreenColors(value: boolean).'), this.setOverrideFlagForModelScreenColors(t);
    }
  }, {
    key: "setOverrideFlagForModelScreenColors",
    value: function setOverrideFlagForModelScreenColors(t) {
      this._isOverriddenModelScreenColors = t;
    }
  }, {
    key: "getOverwriteFlagForDrawableMultiplyColors",
    value: function getOverwriteFlagForDrawableMultiplyColors(t) {
      return v('getOverwriteFlagForDrawableMultiplyColors(drawableindex: number) is a deprecated function. Please use getOverrideFlagForDrawableMultiplyColors(drawableindex: number).'), this.getOverrideFlagForDrawableMultiplyColors(t);
    }
  }, {
    key: "getOverrideFlagForDrawableMultiplyColors",
    value: function getOverrideFlagForDrawableMultiplyColors(t) {
      return this._userMultiplyColors.at(t).isOverridden;
    }
  }, {
    key: "getOverwriteFlagForDrawableScreenColors",
    value: function getOverwriteFlagForDrawableScreenColors(t) {
      return v('getOverwriteFlagForDrawableScreenColors(drawableindex: number) is a deprecated function. Please use getOverrideFlagForDrawableScreenColors(drawableindex: number).'), this.getOverrideFlagForDrawableScreenColors(t);
    }
  }, {
    key: "getOverrideFlagForDrawableScreenColors",
    value: function getOverrideFlagForDrawableScreenColors(t) {
      return this._userScreenColors.at(t).isOverridden;
    }
  }, {
    key: "setOverwriteFlagForDrawableMultiplyColors",
    value: function setOverwriteFlagForDrawableMultiplyColors(t, e) {
      v('setOverwriteFlagForDrawableMultiplyColors(drawableindex: number, value: boolean) is a deprecated function. Please use setOverrideFlagForDrawableMultiplyColors(drawableindex: number, value: boolean).'), this.setOverrideFlagForDrawableMultiplyColors(t, e);
    }
  }, {
    key: "setOverrideFlagForDrawableMultiplyColors",
    value: function setOverrideFlagForDrawableMultiplyColors(t, e) {
      this._userMultiplyColors.at(t).isOverridden = e;
    }
  }, {
    key: "setOverwriteFlagForDrawableScreenColors",
    value: function setOverwriteFlagForDrawableScreenColors(t, e) {
      v('setOverwriteFlagForDrawableScreenColors(drawableindex: number, value: boolean) is a deprecated function. Please use setOverrideFlagForDrawableScreenColors(drawableindex: number, value: boolean).'), this.setOverrideFlagForDrawableScreenColors(t, e);
    }
  }, {
    key: "setOverrideFlagForDrawableScreenColors",
    value: function setOverrideFlagForDrawableScreenColors(t, e) {
      this._userScreenColors.at(t).isOverridden = e;
    }
  }, {
    key: "getOverwriteColorForPartMultiplyColors",
    value: function getOverwriteColorForPartMultiplyColors(t) {
      return v('getOverwriteColorForPartMultiplyColors(partIndex: number) is a deprecated function. Please use getOverrideColorForPartMultiplyColors(partIndex: number).'), this.getOverrideColorForPartMultiplyColors(t);
    }
  }, {
    key: "getOverrideColorForPartMultiplyColors",
    value: function getOverrideColorForPartMultiplyColors(t) {
      return this._userPartMultiplyColors.at(t).isOverridden;
    }
  }, {
    key: "getOverwriteColorForPartScreenColors",
    value: function getOverwriteColorForPartScreenColors(t) {
      return v('getOverwriteColorForPartScreenColors(partIndex: number) is a deprecated function. Please use getOverrideColorForPartScreenColors(partIndex: number).'), this.getOverrideColorForPartScreenColors(t);
    }
  }, {
    key: "getOverrideColorForPartScreenColors",
    value: function getOverrideColorForPartScreenColors(t) {
      return this._userPartScreenColors.at(t).isOverridden;
    }
  }, {
    key: "setOverwriteColorForPartColors",
    value: function setOverwriteColorForPartColors(t, e, i, s) {
      v('setOverwriteColorForPartColors(partIndex: number, value: boolean, partColors: csmVector<PartColorData>, drawableColors: csmVector<DrawableColorData>) is a deprecated function. Please use setOverrideColorForPartColors(partIndex: number, value: boolean, partColors: csmVector<PartColorData>, drawableColors: csmVector<DrawableColorData>).'), this.setOverrideColorForPartColors(t, e, i, s);
    }
  }, {
    key: "setOverrideColorForPartColors",
    value: function setOverrideColorForPartColors(t, e, i, s) {
      i.at(t).isOverridden = e;
      for (var _r20 = 0; _r20 < this._partChildDrawables.at(t).getSize(); ++_r20) {
        var _a13 = this._partChildDrawables.at(t).at(_r20);
        s.at(_a13).isOverridden = e, e && (s.at(_a13).color.r = i.at(t).color.r, s.at(_a13).color.g = i.at(t).color.g, s.at(_a13).color.b = i.at(t).color.b, s.at(_a13).color.a = i.at(t).color.a);
      }
    }
  }, {
    key: "setOverwriteColorForPartMultiplyColors",
    value: function setOverwriteColorForPartMultiplyColors(t, e) {
      v('setOverwriteColorForPartMultiplyColors(partIndex: number, value: boolean) is a deprecated function. Please use setOverrideColorForPartMultiplyColors(partIndex: number, value: boolean).'), this.setOverrideColorForPartMultiplyColors(t, e);
    }
  }, {
    key: "setOverrideColorForPartMultiplyColors",
    value: function setOverrideColorForPartMultiplyColors(t, e) {
      this._userPartMultiplyColors.at(t).isOverridden = e, this.setOverrideColorForPartColors(t, e, this._userPartMultiplyColors, this._userMultiplyColors);
    }
  }, {
    key: "setOverwriteColorForPartScreenColors",
    value: function setOverwriteColorForPartScreenColors(t, e) {
      v('setOverwriteColorForPartScreenColors(partIndex: number, value: boolean) is a deprecated function. Please use setOverrideColorForPartScreenColors(partIndex: number, value: boolean).'), this.setOverrideColorForPartScreenColors(t, e);
    }
  }, {
    key: "setOverrideColorForPartScreenColors",
    value: function setOverrideColorForPartScreenColors(t, e) {
      this._userPartScreenColors.at(t).isOverridden = e, this.setOverrideColorForPartColors(t, e, this._userPartScreenColors, this._userScreenColors);
    }
  }, {
    key: "getDrawableCulling",
    value: function getDrawableCulling(t) {
      if (this.getOverrideFlagForModelCullings() || this.getOverrideFlagForDrawableCullings(t)) return this._userCullings.at(t).isCulling;
      var e = this._model.drawables.constantFlags;
      return !Live2DCubismCore.Utils.hasIsDoubleSidedBit(e[t]);
    }
  }, {
    key: "setDrawableCulling",
    value: function setDrawableCulling(t, e) {
      this._userCullings.at(t).isCulling = e;
    }
  }, {
    key: "getOverwriteFlagForModelCullings",
    value: function getOverwriteFlagForModelCullings() {
      return v('getOverwriteFlagForModelCullings() is a deprecated function. Please use getOverrideFlagForModelCullings().'), this.getOverrideFlagForModelCullings();
    }
  }, {
    key: "getOverrideFlagForModelCullings",
    value: function getOverrideFlagForModelCullings() {
      return this._isOverriddenCullings;
    }
  }, {
    key: "setOverwriteFlagForModelCullings",
    value: function setOverwriteFlagForModelCullings(t) {
      v('setOverwriteFlagForModelCullings(isOverriddenCullings: boolean) is a deprecated function. Please use setOverrideFlagForModelCullings(isOverriddenCullings: boolean).'), this.setOverrideFlagForModelCullings(t);
    }
  }, {
    key: "setOverrideFlagForModelCullings",
    value: function setOverrideFlagForModelCullings(t) {
      this._isOverriddenCullings = t;
    }
  }, {
    key: "getOverwriteFlagForDrawableCullings",
    value: function getOverwriteFlagForDrawableCullings(t) {
      return v('getOverwriteFlagForDrawableCullings(drawableIndex: number) is a deprecated function. Please use getOverrideFlagForDrawableCullings(drawableIndex: number).'), this.getOverrideFlagForDrawableCullings(t);
    }
  }, {
    key: "getOverrideFlagForDrawableCullings",
    value: function getOverrideFlagForDrawableCullings(t) {
      return this._userCullings.at(t).isOverridden;
    }
  }, {
    key: "setOverwriteFlagForDrawableCullings",
    value: function setOverwriteFlagForDrawableCullings(t, e) {
      v('setOverwriteFlagForDrawableCullings(drawableIndex: number, isOverriddenCullings: boolean) is a deprecated function. Please use setOverrideFlagForDrawableCullings(drawableIndex: number, isOverriddenCullings: boolean).'), this.setOverrideFlagForDrawableCullings(t, e);
    }
  }, {
    key: "setOverrideFlagForDrawableCullings",
    value: function setOverrideFlagForDrawableCullings(t, e) {
      this._userCullings.at(t).isOverridden = e;
    }
  }, {
    key: "getModelOapcity",
    value: function getModelOapcity() {
      return this._modelOpacity;
    }
  }, {
    key: "setModelOapcity",
    value: function setModelOapcity(t) {
      this._modelOpacity = t;
    }
  }, {
    key: "getModel",
    value: function getModel() {
      return this._model;
    }
  }, {
    key: "getPartIndex",
    value: function getPartIndex(t) {
      var e;
      var i = this._model.parts.count;
      for (e = 0; e < i; ++e) if (t == this._partIds.at(e)) return e;
      return this._notExistPartId.isExist(t) ? this._notExistPartId.getValue(t) : (e = i + this._notExistPartId.getSize(), this._notExistPartId.setValue(t, e), this._notExistPartOpacities.appendKey(e), e);
    }
  }, {
    key: "getPartId",
    value: function getPartId(t) {
      var e = this._model.parts.ids[t];
      return $.getIdManager().getId(e);
    }
  }, {
    key: "getPartCount",
    value: function getPartCount() {
      return this._model.parts.count;
    }
  }, {
    key: "getPartParentPartIndices",
    value: function getPartParentPartIndices() {
      return this._model.parts.parentIndices;
    }
  }, {
    key: "setPartOpacityByIndex",
    value: function setPartOpacityByIndex(t, e) {
      this._notExistPartOpacities.isExist(t) ? this._notExistPartOpacities.setValue(t, e) : (C(0 <= t && t < this.getPartCount()), this._partOpacities[t] = e);
    }
  }, {
    key: "setPartOpacityById",
    value: function setPartOpacityById(t, e) {
      var i = this.getPartIndex(t);
      i < 0 || this.setPartOpacityByIndex(i, e);
    }
  }, {
    key: "getPartOpacityByIndex",
    value: function getPartOpacityByIndex(t) {
      return this._notExistPartOpacities.isExist(t) ? this._notExistPartOpacities.getValue(t) : (C(0 <= t && t < this.getPartCount()), this._partOpacities[t]);
    }
  }, {
    key: "getPartOpacityById",
    value: function getPartOpacityById(t) {
      var e = this.getPartIndex(t);
      return e < 0 ? 0 : this.getPartOpacityByIndex(e);
    }
  }, {
    key: "getParameterIndex",
    value: function getParameterIndex(t) {
      var e;
      var i = this._model.parameters.count;
      for (e = 0; e < i; ++e) if (t == this._parameterIds.at(e)) return e;
      return this._notExistParameterId.isExist(t) ? this._notExistParameterId.getValue(t) : (e = this._model.parameters.count + this._notExistParameterId.getSize(), this._notExistParameterId.setValue(t, e), this._notExistParameterValues.appendKey(e), e);
    }
  }, {
    key: "getParameterCount",
    value: function getParameterCount() {
      return this._model.parameters.count;
    }
  }, {
    key: "getParameterType",
    value: function getParameterType(t) {
      return this._model.parameters.types[t];
    }
  }, {
    key: "getParameterMaximumValue",
    value: function getParameterMaximumValue(t) {
      return this._model.parameters.maximumValues[t];
    }
  }, {
    key: "getParameterMinimumValue",
    value: function getParameterMinimumValue(t) {
      return this._model.parameters.minimumValues[t];
    }
  }, {
    key: "getParameterDefaultValue",
    value: function getParameterDefaultValue(t) {
      return this._model.parameters.defaultValues[t];
    }
  }, {
    key: "getParameterId",
    value: function getParameterId(t) {
      return $.getIdManager().getId(this._model.parameters.ids[t]);
    }
  }, {
    key: "getParameterValueByIndex",
    value: function getParameterValueByIndex(t) {
      return this._notExistParameterValues.isExist(t) ? this._notExistParameterValues.getValue(t) : (C(0 <= t && t < this.getParameterCount()), this._parameterValues[t]);
    }
  }, {
    key: "getParameterValueById",
    value: function getParameterValueById(t) {
      var e = this.getParameterIndex(t);
      return this.getParameterValueByIndex(e);
    }
  }, {
    key: "setParameterValueByIndex",
    value: function setParameterValueByIndex(t, e) {
      var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
      this._notExistParameterValues.isExist(t) ? this._notExistParameterValues.setValue(t, 1 == i ? e : this._notExistParameterValues.getValue(t) * (1 - i) + e * i) : (C(0 <= t && t < this.getParameterCount()), e = this.isRepeat(t) ? this.getParameterRepeatValue(t, e) : this.getParameterClampValue(t, e), this._parameterValues[t] = 1 == i ? e : this._parameterValues[t] = this._parameterValues[t] * (1 - i) + e * i);
    }
  }, {
    key: "setParameterValueById",
    value: function setParameterValueById(t, e) {
      var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
      var s = this.getParameterIndex(t);
      this.setParameterValueByIndex(s, e, i);
    }
  }, {
    key: "addParameterValueByIndex",
    value: function addParameterValueByIndex(t, e) {
      var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
      this.setParameterValueByIndex(t, this.getParameterValueByIndex(t) + e * i);
    }
  }, {
    key: "addParameterValueById",
    value: function addParameterValueById(t, e) {
      var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
      var s = this.getParameterIndex(t);
      this.addParameterValueByIndex(s, e, i);
    }
  }, {
    key: "isRepeat",
    value: function isRepeat(t) {
      if (this._notExistParameterValues.isExist(t)) return !1;
      var e;
      return C(0 <= t && t < this.getParameterCount()), e = this._isOverriddenParameterRepeat || this._userParameterRepeatDataList.at(t).isOverridden ? this._userParameterRepeatDataList.at(t).isParameterRepeated : 0 != this._model.parameters.repeats[t], e;
    }
  }, {
    key: "getParameterRepeatValue",
    value: function getParameterRepeatValue(t, e) {
      if (this._notExistParameterValues.isExist(t)) return e;
      C(0 <= t && t < this.getParameterCount());
      var i = this._model.parameters.maximumValues[t],
        s = this._model.parameters.minimumValues[t],
        r = i - s;
      if (i < e) {
        var _t89 = Vt.mod(e - i, r);
        e = Number.isNaN(_t89) ? i : s + _t89;
      }
      if (e < s) {
        var _t90 = Vt.mod(s - e, r);
        e = Number.isNaN(_t90) ? s : i - _t90;
      }
      return e;
    }
  }, {
    key: "getParameterClampValue",
    value: function getParameterClampValue(t, e) {
      if (this._notExistParameterValues.isExist(t)) return e;
      C(0 <= t && t < this.getParameterCount());
      var i = this._model.parameters.maximumValues[t],
        s = this._model.parameters.minimumValues[t];
      return Vt.clamp(e, s, i);
    }
  }, {
    key: "getParameterRepeats",
    value: function getParameterRepeats(t) {
      return 0 != this._model.parameters.repeats[t];
    }
  }, {
    key: "multiplyParameterValueById",
    value: function multiplyParameterValueById(t, e) {
      var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
      var s = this.getParameterIndex(t);
      this.multiplyParameterValueByIndex(s, e, i);
    }
  }, {
    key: "multiplyParameterValueByIndex",
    value: function multiplyParameterValueByIndex(t, e) {
      var i = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 1;
      this.setParameterValueByIndex(t, this.getParameterValueByIndex(t) * (1 + (e - 1) * i));
    }
  }, {
    key: "getDrawableIndex",
    value: function getDrawableIndex(t) {
      var e = this._model.drawables.count;
      for (var _i59 = 0; _i59 < e; ++_i59) if (this._drawableIds.at(_i59) == t) return _i59;
      return -1;
    }
  }, {
    key: "getDrawableCount",
    value: function getDrawableCount() {
      return this._model.drawables.count;
    }
  }, {
    key: "getDrawableId",
    value: function getDrawableId(t) {
      var e = this._model.drawables.ids;
      return $.getIdManager().getId(e[t]);
    }
  }, {
    key: "getDrawableRenderOrders",
    value: function getDrawableRenderOrders() {
      return this._model.drawables.renderOrders;
    }
  }, {
    key: "getDrawableTextureIndices",
    value: function getDrawableTextureIndices(t) {
      return this.getDrawableTextureIndex(t);
    }
  }, {
    key: "getDrawableTextureIndex",
    value: function getDrawableTextureIndex(t) {
      return this._model.drawables.textureIndices[t];
    }
  }, {
    key: "getDrawableDynamicFlagVertexPositionsDidChange",
    value: function getDrawableDynamicFlagVertexPositionsDidChange(t) {
      var e = this._model.drawables.dynamicFlags;
      return Live2DCubismCore.Utils.hasVertexPositionsDidChangeBit(e[t]);
    }
  }, {
    key: "getDrawableVertexIndexCount",
    value: function getDrawableVertexIndexCount(t) {
      return this._model.drawables.indexCounts[t];
    }
  }, {
    key: "getDrawableVertexCount",
    value: function getDrawableVertexCount(t) {
      return this._model.drawables.vertexCounts[t];
    }
  }, {
    key: "getDrawableVertices",
    value: function getDrawableVertices(t) {
      return this.getDrawableVertexPositions(t);
    }
  }, {
    key: "getDrawableVertexIndices",
    value: function getDrawableVertexIndices(t) {
      return this._model.drawables.indices[t];
    }
  }, {
    key: "getDrawableVertexPositions",
    value: function getDrawableVertexPositions(t) {
      return this._model.drawables.vertexPositions[t];
    }
  }, {
    key: "getDrawableVertexUvs",
    value: function getDrawableVertexUvs(t) {
      return this._model.drawables.vertexUvs[t];
    }
  }, {
    key: "getDrawableOpacity",
    value: function getDrawableOpacity(t) {
      return this._model.drawables.opacities[t];
    }
  }, {
    key: "getDrawableMultiplyColor",
    value: function getDrawableMultiplyColor(t) {
      var e = this._model.drawables.multiplyColors,
        i = 4 * t,
        s = new f();
      return s.r = e[i], s.g = e[i + 1], s.b = e[i + 2], s.a = e[i + 3], s;
    }
  }, {
    key: "getDrawableScreenColor",
    value: function getDrawableScreenColor(t) {
      var e = this._model.drawables.screenColors,
        i = 4 * t,
        s = new f();
      return s.r = e[i], s.g = e[i + 1], s.b = e[i + 2], s.a = e[i + 3], s;
    }
  }, {
    key: "getDrawableParentPartIndex",
    value: function getDrawableParentPartIndex(t) {
      return this._model.drawables.parentPartIndices[t];
    }
  }, {
    key: "getDrawableBlendMode",
    value: function getDrawableBlendMode(t) {
      var e = this._model.drawables.constantFlags;
      return Live2DCubismCore.Utils.hasBlendAdditiveBit(e[t]) ? h.CubismBlendMode_Additive : Live2DCubismCore.Utils.hasBlendMultiplicativeBit(e[t]) ? h.CubismBlendMode_Multiplicative : h.CubismBlendMode_Normal;
    }
  }, {
    key: "getDrawableInvertedMaskBit",
    value: function getDrawableInvertedMaskBit(t) {
      var e = this._model.drawables.constantFlags;
      return Live2DCubismCore.Utils.hasIsInvertedMaskBit(e[t]);
    }
  }, {
    key: "getDrawableMasks",
    value: function getDrawableMasks() {
      return this._model.drawables.masks;
    }
  }, {
    key: "getDrawableMaskCounts",
    value: function getDrawableMaskCounts() {
      return this._model.drawables.maskCounts;
    }
  }, {
    key: "isUsingMasking",
    value: function isUsingMasking() {
      for (var _t91 = 0; _t91 < this._model.drawables.count; ++_t91) if (!(this._model.drawables.maskCounts[_t91] <= 0)) return !0;
      return !1;
    }
  }, {
    key: "getDrawableDynamicFlagIsVisible",
    value: function getDrawableDynamicFlagIsVisible(t) {
      var e = this._model.drawables.dynamicFlags;
      return Live2DCubismCore.Utils.hasIsVisibleBit(e[t]);
    }
  }, {
    key: "getDrawableDynamicFlagVisibilityDidChange",
    value: function getDrawableDynamicFlagVisibilityDidChange(t) {
      var e = this._model.drawables.dynamicFlags;
      return Live2DCubismCore.Utils.hasVisibilityDidChangeBit(e[t]);
    }
  }, {
    key: "getDrawableDynamicFlagOpacityDidChange",
    value: function getDrawableDynamicFlagOpacityDidChange(t) {
      var e = this._model.drawables.dynamicFlags;
      return Live2DCubismCore.Utils.hasOpacityDidChangeBit(e[t]);
    }
  }, {
    key: "getDrawableDynamicFlagRenderOrderDidChange",
    value: function getDrawableDynamicFlagRenderOrderDidChange(t) {
      var e = this._model.drawables.dynamicFlags;
      return Live2DCubismCore.Utils.hasRenderOrderDidChangeBit(e[t]);
    }
  }, {
    key: "getDrawableDynamicFlagBlendColorDidChange",
    value: function getDrawableDynamicFlagBlendColorDidChange(t) {
      var e = this._model.drawables.dynamicFlags;
      return Live2DCubismCore.Utils.hasBlendColorDidChangeBit(e[t]);
    }
  }, {
    key: "loadParameters",
    value: function loadParameters() {
      var t = this._model.parameters.count;
      var e = this._savedParameters.getSize();
      t > e && (t = e);
      for (var _e99 = 0; _e99 < t; ++_e99) this._parameterValues[_e99] = this._savedParameters.at(_e99);
    }
  }, {
    key: "initialize",
    value: function initialize() {
      C(this._model), this._parameterValues = this._model.parameters.values, this._partOpacities = this._model.parts.opacities, this._parameterMaximumValues = this._model.parameters.maximumValues, this._parameterMinimumValues = this._model.parameters.minimumValues;
      {
        var _t92 = this._model.parameters.ids,
          _e100 = this._model.parameters.count;
        this._parameterIds.prepareCapacity(_e100), this._userParameterRepeatDataList.prepareCapacity(_e100);
        for (var _i60 = 0; _i60 < _e100; ++_i60) this._parameterIds.pushBack($.getIdManager().getId(_t92[_i60])), this._userParameterRepeatDataList.pushBack(new Yi(!1, !1));
      }
      var t = this._model.parts.count;
      {
        var _e101 = this._model.parts.ids;
        this._partIds.prepareCapacity(t);
        for (var _i61 = 0; _i61 < t; ++_i61) this._partIds.pushBack($.getIdManager().getId(_e101[_i61]));
        this._userPartMultiplyColors.prepareCapacity(t), this._userPartScreenColors.prepareCapacity(t), this._partChildDrawables.prepareCapacity(t);
      }
      {
        var _i62 = this._model.drawables.ids,
          _s45 = this._model.drawables.count;
        this._userMultiplyColors.prepareCapacity(_s45), this._userScreenColors.prepareCapacity(_s45), this._userCullings.prepareCapacity(_s45);
        var _r21 = new qi(!1, !1);
        for (var _i63 = 0; _i63 < t; ++_i63) {
          var _t93 = new f(1, 1, 1, 1),
            _r22 = new f(0, 0, 0, 1),
            _a14 = new Hi(!1, _t93),
            _n14 = new Hi(!1, _r22);
          this._userPartMultiplyColors.pushBack(_a14), this._userPartScreenColors.pushBack(_n14), this._partChildDrawables.pushBack(new e()), this._partChildDrawables.at(_i63).prepareCapacity(_s45);
        }
        for (var _t94 = 0; _t94 < _s45; ++_t94) {
          var _e102 = new f(1, 1, 1, 1),
            _s46 = new f(0, 0, 0, 1),
            _a15 = new ji(!1, _e102),
            _n15 = new ji(!1, _s46);
          this._drawableIds.pushBack($.getIdManager().getId(_i62[_t94])), this._userMultiplyColors.pushBack(_a15), this._userScreenColors.pushBack(_n15), this._userCullings.pushBack(_r21);
          var _o9 = this.getDrawableParentPartIndex(_t94);
          _o9 >= 0 && this._partChildDrawables.at(_o9).pushBack(_t94);
        }
      }
    }
  }, {
    key: "release",
    value: function release() {
      this._model.release(), this._model = null;
    }
  }]);
  return Wi;
}();
(Gi || (Gi = {})).CubismModel = Wi;
var Ji = /*#__PURE__*/function () {
  function Ji(t) {
    (0,classCallCheck/* default */.A)(this, Ji);
    this._moc = t, this._modelCount = 0, this._mocVersion = 0;
  }
  (0,createClass/* default */.A)(Ji, [{
    key: "createModel",
    value: function createModel() {
      var t = null;
      var e = Live2DCubismCore.Model.fromMoc(this._moc);
      return e && (t = new Wi(e), t.initialize(), ++this._modelCount), t;
    }
  }, {
    key: "deleteModel",
    value: function deleteModel(t) {
      null != t && (t.release(), t = null, --this._modelCount);
    }
  }, {
    key: "release",
    value: function release() {
      C(0 == this._modelCount), this._moc._release(), this._moc = null;
    }
  }, {
    key: "getLatestMocVersion",
    value: function getLatestMocVersion() {
      return Live2DCubismCore.Version.csmGetLatestMocVersion();
    }
  }, {
    key: "getMocVersion",
    value: function getMocVersion() {
      return this._mocVersion;
    }
  }], [{
    key: "create",
    value: function create(t, e) {
      var i = null;
      if (e) {
        if (!this.hasMocConsistency(t)) return b('Inconsistent MOC3.'), i;
      }
      var s = Live2DCubismCore.Moc.fromArrayBuffer(t);
      return s && (i = new Ji(s), i._mocVersion = Live2DCubismCore.Version.csmGetMocVersion(s, t)), i;
    }
  }, {
    key: "delete",
    value: function _delete(t) {
      t._moc._release(), t._moc = null, t = null;
    }
  }, {
    key: "hasMocConsistency",
    value: function hasMocConsistency(t) {
      return 1 === Live2DCubismCore.Moc.prototype.hasMocConsistency(t);
    }
  }]);
  return Ji;
}();
(Xi || (Xi = {})).CubismMoc = Ji;
var $i = 'Meta',
  Zi = 'UserData';
var Ki = /*#__PURE__*/function () {
  function Ki(t, e) {
    (0,classCallCheck/* default */.A)(this, Ki);
    this._json = L.create(t, e);
  }
  (0,createClass/* default */.A)(Ki, [{
    key: "release",
    value: function release() {
      L.delete(this._json);
    }
  }, {
    key: "getUserDataCount",
    value: function getUserDataCount() {
      return this._json.getRoot().getValueByString($i).getValueByString('UserDataCount').toInt();
    }
  }, {
    key: "getTotalUserDataSize",
    value: function getTotalUserDataSize() {
      return this._json.getRoot().getValueByString($i).getValueByString('TotalUserDataSize').toInt();
    }
  }, {
    key: "getUserDataTargetType",
    value: function getUserDataTargetType(t) {
      return this._json.getRoot().getValueByString(Zi).getValueByIndex(t).getValueByString('Target').getRawString();
    }
  }, {
    key: "getUserDataId",
    value: function getUserDataId(t) {
      return $.getIdManager().getId(this._json.getRoot().getValueByString(Zi).getValueByIndex(t).getValueByString('Id').getRawString());
    }
  }, {
    key: "getUserDataValue",
    value: function getUserDataValue(t) {
      return this._json.getRoot().getValueByString(Zi).getValueByIndex(t).getValueByString('Value').getRawString();
    }
  }]);
  return Ki;
}();
var Qi;
(Qi || (Qi = {})).CubismModelUserDataJson = Ki;
var ts = /*#__PURE__*/(0,createClass/* default */.A)(function ts() {
  (0,classCallCheck/* default */.A)(this, ts);
});
var es = /*#__PURE__*/function () {
  function es() {
    (0,classCallCheck/* default */.A)(this, es);
    this._userDataNodes = new e(), this._artMeshUserDataNode = new e();
  }
  (0,createClass/* default */.A)(es, [{
    key: "getArtMeshUserDatas",
    value: function getArtMeshUserDatas() {
      return this._artMeshUserDataNode;
    }
  }, {
    key: "parseUserData",
    value: function parseUserData(t, e) {
      var i = new Ki(t, e);
      if (!i) return i.release(), void (i = void 0);
      var s = $.getIdManager().getId('ArtMesh'),
        r = i.getUserDataCount();
      for (var _t95 = 0; _t95 < r; _t95++) {
        var _e103 = new ts();
        _e103.targetId = i.getUserDataId(_t95), _e103.targetType = $.getIdManager().getId(i.getUserDataTargetType(_t95)), _e103.value = new g(i.getUserDataValue(_t95)), this._userDataNodes.pushBack(_e103), _e103.targetType == s && this._artMeshUserDataNode.pushBack(_e103);
      }
      i.release(), i = void 0;
    }
  }, {
    key: "release",
    value: function release() {
      for (var _t96 = 0; _t96 < this._userDataNodes.getSize(); ++_t96) this._userDataNodes.set(_t96, null);
      this._userDataNodes = null;
    }
  }], [{
    key: "create",
    value: function create(t, e) {
      var i = new es();
      return i.parseUserData(t, e), i;
    }
  }, {
    key: "delete",
    value: function _delete(t) {
      null != t && (t.release(), t = null);
    }
  }]);
  return es;
}();
var is, ss;
!function (t) {
  t.CubismModelUserData = es, t.CubismModelUserDataNode = ts;
}(is || (is = {}));
var rs = /*#__PURE__*/function () {
  function rs() {
    (0,classCallCheck/* default */.A)(this, rs);
    this._moc = null, this._model = null, this._motionManager = null, this._expressionManager = null, this._eyeBlink = null, this._breath = null, this._modelMatrix = null, this._pose = null, this._dragManager = null, this._physics = null, this._modelUserData = null, this._initialized = !1, this._updating = !1, this._opacity = 1, this._lipsync = !0, this._lastLipSyncValue = 0, this._dragX = 0, this._dragY = 0, this._accelerationX = 0, this._accelerationY = 0, this._accelerationZ = 0, this._mocConsistency = !1, this._debugMode = !1, this._renderer = null, this._motionManager = new we(), this._motionManager.setEventCallback(rs.cubismDefaultMotionEventCallback, this), this._expressionManager = new Zt(), this._dragManager = new Et();
  }
  (0,createClass/* default */.A)(rs, [{
    key: "isInitialized",
    value: function isInitialized() {
      return this._initialized;
    }
  }, {
    key: "setInitialized",
    value: function setInitialized(t) {
      this._initialized = t;
    }
  }, {
    key: "isUpdating",
    value: function isUpdating() {
      return this._updating;
    }
  }, {
    key: "setUpdating",
    value: function setUpdating(t) {
      this._updating = t;
    }
  }, {
    key: "setDragging",
    value: function setDragging(t, e) {
      this._dragManager.set(t, e);
    }
  }, {
    key: "setAcceleration",
    value: function setAcceleration(t, e, i) {
      this._accelerationX = t, this._accelerationY = e, this._accelerationZ = i;
    }
  }, {
    key: "getModelMatrix",
    value: function getModelMatrix() {
      return this._modelMatrix;
    }
  }, {
    key: "setOpacity",
    value: function setOpacity(t) {
      this._opacity = t;
    }
  }, {
    key: "getOpacity",
    value: function getOpacity() {
      return this._opacity;
    }
  }, {
    key: "loadModel",
    value: function loadModel(t) {
      var e = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : !1;
      this._moc = Ji.create(t, e), null != this._moc ? (this._model = this._moc.createModel(), null != this._model ? (this._model.saveParameters(), this._modelMatrix = new Ft(this._model.getCanvasWidth(), this._model.getCanvasHeight())) : b('Failed to CreateModel().')) : b('Failed to CubismMoc.create().');
    }
  }, {
    key: "loadMotion",
    value: function loadMotion(t, e, i, s, r, a, n, o) {
      var l = arguments.length > 8 && arguments[8] !== undefined ? arguments[8] : !1;
      if (null == t || 0 == e) return b('Failed to loadMotion().'), null;
      var h = Be.create(t, e, s, r, l);
      if (null == h) return b('Failed to create motion from buffer in LoadMotion()'), null;
      if (a) {
        var _t97 = a.getMotionFadeInTimeValue(n, o);
        _t97 >= 0 && h.setFadeInTime(_t97);
        var _e104 = a.getMotionFadeOutTimeValue(n, o);
        _e104 >= 0 && h.setFadeOutTime(_e104);
      }
      return h;
    }
  }, {
    key: "loadExpression",
    value: function loadExpression(t, e, i) {
      return null == t || 0 == e ? (b('Failed to loadExpression().'), null) : Ot.create(t, e);
    }
  }, {
    key: "loadPose",
    value: function loadPose(t, e) {
      null != t && 0 != e ? this._pose = Mt.create(t, e) : b('Failed to loadPose().');
    }
  }, {
    key: "loadUserData",
    value: function loadUserData(t, e) {
      null != t && 0 != e ? this._modelUserData = es.create(t, e) : b('Failed to loadUserData().');
    }
  }, {
    key: "loadPhysics",
    value: function loadPhysics(t, e) {
      null != t && 0 != e ? this._physics = ii.create(t, e) : b('Failed to loadPhysics().');
    }
  }, {
    key: "isHit",
    value: function isHit(t, e, i) {
      var s = this._model.getDrawableIndex(t);
      if (s < 0) return !1;
      var r = this._model.getDrawableVertexCount(s),
        a = this._model.getDrawableVertices(s);
      var n = a[0],
        o = a[0],
        l = a[1],
        h = a[1];
      for (var _t98 = 1; _t98 < r; ++_t98) {
        var _e105 = a[W.vertexOffset + _t98 * W.vertexStep],
          _i64 = a[W.vertexOffset + _t98 * W.vertexStep + 1];
        _e105 < n && (n = _e105), _e105 > o && (o = _e105), _i64 < l && (l = _i64), _i64 > h && (h = _i64);
      }
      var u = this._modelMatrix.invertTransformX(e),
        g = this._modelMatrix.invertTransformY(i);
      return n <= u && u <= o && l <= g && g <= h;
    }
  }, {
    key: "getModel",
    value: function getModel() {
      return this._model;
    }
  }, {
    key: "getRenderer",
    value: function getRenderer() {
      return this._renderer;
    }
  }, {
    key: "createRenderer",
    value: function createRenderer() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1;
      this._renderer && this.deleteRenderer(), this._renderer = new zi(), this._renderer.initialize(this._model, t);
    }
  }, {
    key: "deleteRenderer",
    value: function deleteRenderer() {
      null != this._renderer && (this._renderer.release(), this._renderer = null);
    }
  }, {
    key: "motionEventFired",
    value: function motionEventFired(t) {
      M('{0}', t.s);
    }
  }, {
    key: "release",
    value: function release() {
      null != this._motionManager && (this._motionManager.release(), this._motionManager = null), null != this._expressionManager && (this._expressionManager.release(), this._expressionManager = null), null != this._moc && (this._moc.deleteModel(this._model), this._moc.release(), this._moc = null), this._modelMatrix = null, Mt.delete(this._pose), St.delete(this._eyeBlink), ft.delete(this._breath), this._dragManager = null, ii.delete(this._physics), es.delete(this._modelUserData), this.deleteRenderer();
    }
  }], [{
    key: "cubismDefaultMotionEventCallback",
    value: function cubismDefaultMotionEventCallback(t, e, i) {
      null != i && i.motionEventFired(e);
    }
  }]);
  return rs;
}();
(ss || (ss = {})).CubismUserModel = rs;
var as = null;
var ns = /*#__PURE__*/function () {
  function ns() {
    var _this18 = this;
    (0,classCallCheck/* default */.A)(this, ns);
    this.loadFiletoBytes = function (t, e) {
      _this18._byteReader._fileByte = t, _this18._byteReader._fileDataView = new DataView(_this18._byteReader._fileByte), _this18._byteReader._fileSize = e;
    }, this._pcmData = null, this._userTimeSeconds = 0, this._lastRms = 0, this._sampleOffset = 0, this._wavFileInfo = new os(), this._byteReader = new ls();
  }
  (0,createClass/* default */.A)(ns, [{
    key: "update",
    value: function update(t) {
      var e, i;
      if (null == this._pcmData || this._sampleOffset >= this._wavFileInfo._samplesPerChannel) return this._lastRms = 0, !1;
      this._userTimeSeconds += t, e = Math.floor(this._userTimeSeconds * this._wavFileInfo._samplingRate), e > this._wavFileInfo._samplesPerChannel && (e = this._wavFileInfo._samplesPerChannel), i = 0;
      for (var _t99 = 0; _t99 < this._wavFileInfo._numberOfChannels; _t99++) {
        for (var _s47 = this._sampleOffset; _s47 < e; _s47++) {
          var _e106 = this._pcmData[_t99][_s47];
          i += _e106 * _e106;
        }
      }
      return i = Math.sqrt(i / (this._wavFileInfo._numberOfChannels * (e - this._sampleOffset))), this._lastRms = i, this._sampleOffset = e, !0;
    }
  }, {
    key: "start",
    value: function start(t) {
      this._sampleOffset = 0, this._userTimeSeconds = 0, this._lastRms = 0, this.loadWavFile(t);
    }
  }, {
    key: "getRms",
    value: function getRms() {
      return this._lastRms;
    }
  }, {
    key: "loadWavFile",
    value: function loadWavFile(t) {
      var _this19 = this;
      return new Promise(function (e) {
        var i = !1;
        null != _this19._pcmData && _this19.releasePcmData();
        (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee2() {
          var _t100, _t101, _t102, _t103, _e107;
          return (0,regeneratorRuntime/* default */.A)().wrap(function _callee2$(_context2) {
            while (1) switch (_context2.prev = _context2.next) {
              case 0:
                _context2.next = 2;
                return (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee() {
                  return (0,regeneratorRuntime/* default */.A)().wrap(function _callee$(_context) {
                    while (1) switch (_context.prev = _context.next) {
                      case 0:
                        return _context.abrupt("return", fetch(t).then(function (t) {
                          return t.arrayBuffer();
                        }));
                      case 1:
                      case "end":
                        return _context.stop();
                    }
                  }, _callee);
                }))();
              case 2:
                _this19._byteReader._fileByte = _context2.sent;
                _this19._byteReader._fileDataView = new DataView(_this19._byteReader._fileByte);
                _this19._byteReader._fileSize = _this19._byteReader._fileByte.byteLength;
                _this19._byteReader._readOffset = 0;
                if (!(null == _this19._byteReader._fileByte || _this19._byteReader._fileSize < 4)) {
                  _context2.next = 10;
                  break;
                }
                e(!1);
                _context2.next = 35;
                break;
              case 10:
                _this19._wavFileInfo._fileName = t;
                _context2.prev = 11;
                if (_this19._byteReader.getCheckSignature('RIFF')) {
                  _context2.next = 14;
                  break;
                }
                throw i = !1, new Error('Cannot find Signeture "RIFF".');
              case 14:
                if (!(_this19._byteReader.get32LittleEndian(), !_this19._byteReader.getCheckSignature('WAVE'))) {
                  _context2.next = 16;
                  break;
                }
                throw i = !1, new Error('Cannot find Signeture "WAVE".');
              case 16:
                if (_this19._byteReader.getCheckSignature('fmt ')) {
                  _context2.next = 18;
                  break;
                }
                throw i = !1, new Error('Cannot find Signeture "fmt".');
              case 18:
                _t100 = _this19._byteReader.get32LittleEndian();
                if (!(1 != _this19._byteReader.get16LittleEndian())) {
                  _context2.next = 21;
                  break;
                }
                throw i = !1, new Error('File is not linear PCM.');
              case 21:
                for (_this19._wavFileInfo._numberOfChannels = _this19._byteReader.get16LittleEndian(), _this19._wavFileInfo._samplingRate = _this19._byteReader.get32LittleEndian(), _this19._byteReader.get32LittleEndian(), _this19._byteReader.get16LittleEndian(), _this19._wavFileInfo._bitsPerSample = _this19._byteReader.get16LittleEndian(), _t100 > 16 && (_this19._byteReader._readOffset += _t100 - 16); !_this19._byteReader.getCheckSignature("data") && _this19._byteReader._readOffset < _this19._byteReader._fileSize;) _this19._byteReader._readOffset += _this19._byteReader.get32LittleEndian() + 4;
                if (!(_this19._byteReader._readOffset >= _this19._byteReader._fileSize)) {
                  _context2.next = 24;
                  break;
                }
                throw i = !1, new Error('Cannot find "data" Chunk.');
              case 24:
                _t101 = _this19._byteReader.get32LittleEndian();
                _this19._wavFileInfo._samplesPerChannel = 8 * _t101 / (_this19._wavFileInfo._bitsPerSample * _this19._wavFileInfo._numberOfChannels);
                _this19._pcmData = new Array(_this19._wavFileInfo._numberOfChannels);
                for (_t102 = 0; _t102 < _this19._wavFileInfo._numberOfChannels; _t102++) _this19._pcmData[_t102] = new Float32Array(_this19._wavFileInfo._samplesPerChannel);
                for (_t103 = 0; _t103 < _this19._wavFileInfo._samplesPerChannel; _t103++) for (_e107 = 0; _e107 < _this19._wavFileInfo._numberOfChannels; _e107++) _this19._pcmData[_e107][_t103] = _this19.getPcmSample();
                i = !0, e(i);
                _context2.next = 35;
                break;
              case 32:
                _context2.prev = 32;
                _context2.t0 = _context2["catch"](11);
                console.log(_context2.t0);
              case 35:
              case "end":
                return _context2.stop();
            }
          }, _callee2, null, [[11, 32]]);
        }))().then(function () {
          e(i);
        });
      });
    }
  }, {
    key: "getPcmSample",
    value: function getPcmSample() {
      var t;
      switch (this._wavFileInfo._bitsPerSample) {
        case 8:
          t = this._byteReader.get8() - 128, t <<= 24;
          break;
        case 16:
          t = this._byteReader.get16LittleEndian() << 16;
          break;
        case 24:
          t = this._byteReader.get24LittleEndian() << 8;
          break;
        default:
          t = 0;
      }
      return t / 2147483647;
    }
  }, {
    key: "getPcmDataChannel",
    value: function getPcmDataChannel(t) {
      return this._pcmData && t < this._pcmData.length ? Float32Array.from(this._pcmData[t]) : null;
    }
  }, {
    key: "getWavSamplingRate",
    value: function getWavSamplingRate() {
      return !this._wavFileInfo || this._wavFileInfo._samplingRate < 1 ? null : this._wavFileInfo._samplingRate;
    }
  }, {
    key: "releasePcmData",
    value: function releasePcmData() {
      for (var _t104 = 0; _t104 < this._wavFileInfo._numberOfChannels; _t104++) this._pcmData[_t104] = null;
      delete this._pcmData, this._pcmData = null;
    }
  }], [{
    key: "getInstance",
    value: function getInstance() {
      return null == as && (as = new ns()), as;
    }
  }, {
    key: "releaseInstance",
    value: function releaseInstance() {
      null != as && (as = void 0), as = null;
    }
  }]);
  return ns;
}();
var os = /*#__PURE__*/(0,createClass/* default */.A)(function os() {
  (0,classCallCheck/* default */.A)(this, os);
  this._fileName = '', this._numberOfChannels = 0, this._bitsPerSample = 0, this._samplingRate = 0, this._samplesPerChannel = 0;
});
var ls = /*#__PURE__*/function () {
  function ls() {
    (0,classCallCheck/* default */.A)(this, ls);
    this._fileByte = null, this._fileDataView = null, this._fileSize = 0, this._readOffset = 0;
  }
  (0,createClass/* default */.A)(ls, [{
    key: "get8",
    value: function get8() {
      var t = this._fileDataView.getUint8(this._readOffset);
      return this._readOffset++, t;
    }
  }, {
    key: "get16LittleEndian",
    value: function get16LittleEndian() {
      var t = this._fileDataView.getUint8(this._readOffset + 1) << 8 | this._fileDataView.getUint8(this._readOffset);
      return this._readOffset += 2, t;
    }
  }, {
    key: "get24LittleEndian",
    value: function get24LittleEndian() {
      var t = this._fileDataView.getUint8(this._readOffset + 2) << 16 | this._fileDataView.getUint8(this._readOffset + 1) << 8 | this._fileDataView.getUint8(this._readOffset);
      return this._readOffset += 3, t;
    }
  }, {
    key: "get32LittleEndian",
    value: function get32LittleEndian() {
      var t = this._fileDataView.getUint8(this._readOffset + 3) << 24 | this._fileDataView.getUint8(this._readOffset + 2) << 16 | this._fileDataView.getUint8(this._readOffset + 1) << 8 | this._fileDataView.getUint8(this._readOffset);
      return this._readOffset += 4, t;
    }
  }, {
    key: "getCheckSignature",
    value: function getCheckSignature(t) {
      var e = new Uint8Array(4),
        i = new TextEncoder().encode(t);
      if (4 != t.length) return !1;
      for (var _t105 = 0; _t105 < 4; _t105++) e[_t105] = this.get8();
      return e[0] == i[0] && e[1] == i[1] && e[2] == i[2] && e[3] == i[3];
    }
  }]);
  return ls;
}();
var hs, us;
!function (t) {
  t[t.LoadAssets = 0] = 'LoadAssets', t[t.LoadModel = 1] = 'LoadModel', t[t.WaitLoadModel = 2] = 'WaitLoadModel', t[t.LoadExpression = 3] = 'LoadExpression', t[t.WaitLoadExpression = 4] = 'WaitLoadExpression', t[t.LoadPhysics = 5] = 'LoadPhysics', t[t.WaitLoadPhysics = 6] = 'WaitLoadPhysics', t[t.LoadPose = 7] = 'LoadPose', t[t.WaitLoadPose = 8] = 'WaitLoadPose', t[t.SetupEyeBlink = 9] = 'SetupEyeBlink', t[t.SetupBreath = 10] = 'SetupBreath', t[t.LoadUserData = 11] = 'LoadUserData', t[t.WaitLoadUserData = 12] = 'WaitLoadUserData', t[t.SetupEyeBlinkIds = 13] = 'SetupEyeBlinkIds', t[t.SetupLipSyncIds = 14] = 'SetupLipSyncIds', t[t.SetupLayout = 15] = 'SetupLayout', t[t.LoadMotion = 16] = 'LoadMotion', t[t.WaitLoadMotion = 17] = 'WaitLoadMotion', t[t.CompleteInitialize = 18] = 'CompleteInitialize', t[t.CompleteSetupModel = 19] = 'CompleteSetupModel', t[t.LoadTexture = 20] = 'LoadTexture', t[t.WaitLoadTexture = 21] = 'WaitLoadTexture', t[t.CompleteSetup = 22] = 'CompleteSetup';
}(hs || (hs = {}));
var gs = /*#__PURE__*/function (_rs) {
  (0,inherits/* default */.A)(gs, _rs);
  function gs() {
    var _this20;
    (0,classCallCheck/* default */.A)(this, gs);
    _this20 = (0,callSuper/* default */.A)(this, gs), _this20._modelSetting = null, _this20._modelHomeDir = null, _this20._userTimeSeconds = 0, _this20._eyeBlinkIds = new e(), _this20._lipSyncIds = new e(), _this20._motions = new I(), _this20._expressions = new I(), _this20._hitArea = new e(), _this20._userArea = new e(), _this20._idParamAngleX = $.getIdManager().getId(ot.ParamAngleX), _this20._idParamAngleY = $.getIdManager().getId(ot.ParamAngleY), _this20._idParamAngleZ = $.getIdManager().getId(ot.ParamAngleZ), _this20._idParamEyeBallX = $.getIdManager().getId(ot.ParamEyeBallX), _this20._idParamEyeBallY = $.getIdManager().getId(ot.ParamEyeBallY), _this20._idParamBodyAngleX = $.getIdManager().getId(ot.ParamBodyAngleX), _this20._mocConsistency = !0, _this20._motionConsistency = !0, _this20._state = hs.LoadAssets, _this20._expressionCount = 0, _this20._textureCount = 0, _this20._motionCount = 0, _this20._allMotionCount = 0, _this20._wavFileHandler = new ns(), _this20._consistency = !1;
    return _this20;
  }
  (0,createClass/* default */.A)(gs, [{
    key: "loadAssets",
    value: function loadAssets(t, e) {
      var _this21 = this;
      this._modelHomeDir = t, fetch("".concat(this._modelHomeDir).concat(e)).then(function (t) {
        return t.arrayBuffer();
      }).then(function (t) {
        var e = new pt(t, t.byteLength);
        _this21._state = hs.LoadModel, _this21.setupModel(e);
      }).catch(function (t) {
        b("Failed to load file ".concat(_this21._modelHomeDir).concat(e));
      });
    }
  }, {
    key: "setupModel",
    value: function setupModel(t) {
      var _this22 = this;
      if (this._updating = !0, this._initialized = !1, this._modelSetting = t, '' != this._modelSetting.getModelFileName()) {
        var _t106 = this._modelSetting.getModelFileName();
        fetch("".concat(this._modelHomeDir).concat(_t106)).then(function (e) {
          return e.ok ? e.arrayBuffer() : e.status >= 400 ? (b("Failed to load file ".concat(_this22._modelHomeDir).concat(_t106)), new ArrayBuffer(0)) : void 0;
        }).then(function (t) {
          _this22.loadModel(t, _this22._mocConsistency), _this22._state = hs.LoadExpression, i();
        }), this._state = hs.WaitLoadModel;
      } else {
        at.printMessage('Model data does not exist.');
      }
      var i = function i() {
          if (_this22._modelSetting.getExpressionCount() > 0) {
            var _t107 = _this22._modelSetting.getExpressionCount();
            var _loop = function _loop() {
              var i = _this22._modelSetting.getExpressionName(_e108),
                r = _this22._modelSetting.getExpressionFileName(_e108);
              fetch("".concat(_this22._modelHomeDir).concat(r)).then(function (t) {
                return t.ok ? t.arrayBuffer() : t.status >= 400 ? (b("Failed to load file ".concat(_this22._modelHomeDir).concat(r)), new ArrayBuffer(0)) : void 0;
              }).then(function (e) {
                var r = _this22.loadExpression(e, e.byteLength, i);
                null != _this22._expressions.getValue(i) && (Lt.delete(_this22._expressions.getValue(i)), _this22._expressions.setValue(i, null)), _this22._expressions.setValue(i, r), _this22._expressionCount++, _this22._expressionCount >= _t107 && (_this22._state = hs.LoadPhysics, s());
              });
            };
            for (var _e108 = 0; _e108 < _t107; _e108++) {
              _loop();
            }
            _this22._state = hs.WaitLoadExpression;
          } else {
            _this22._state = hs.LoadPhysics, s();
          }
        },
        s = function s() {
          if ('' != _this22._modelSetting.getPhysicsFileName()) {
            var _t108 = _this22._modelSetting.getPhysicsFileName();
            fetch("".concat(_this22._modelHomeDir).concat(_t108)).then(function (e) {
              return e.ok ? e.arrayBuffer() : e.status >= 400 ? (b("Failed to load file ".concat(_this22._modelHomeDir).concat(_t108)), new ArrayBuffer(0)) : void 0;
            }).then(function (t) {
              _this22.loadPhysics(t, t.byteLength), _this22._state = hs.LoadPose, r();
            }), _this22._state = hs.WaitLoadPhysics;
          } else {
            _this22._state = hs.LoadPose, r();
          }
        },
        r = function r() {
          if ('' != _this22._modelSetting.getPoseFileName()) {
            var _t109 = _this22._modelSetting.getPoseFileName();
            fetch("".concat(_this22._modelHomeDir).concat(_t109)).then(function (e) {
              return e.ok ? e.arrayBuffer() : e.status >= 400 ? (b("Failed to load file ".concat(_this22._modelHomeDir).concat(_t109)), new ArrayBuffer(0)) : void 0;
            }).then(function (t) {
              _this22.loadPose(t, t.byteLength), _this22._state = hs.SetupEyeBlink, a();
            }), _this22._state = hs.WaitLoadPose;
          } else {
            _this22._state = hs.SetupEyeBlink, a();
          }
        },
        a = function a() {
          _this22._modelSetting.getEyeBlinkParameterCount() > 0 && (_this22._eyeBlink = St.create(_this22._modelSetting), _this22._state = hs.SetupBreath), n();
        },
        n = function n() {
          _this22._breath = ft.create();
          var t = new e();
          t.pushBack(new yt(_this22._idParamAngleX, 0, 15, 6.5345, .5)), t.pushBack(new yt(_this22._idParamAngleY, 0, 8, 3.5345, .5)), t.pushBack(new yt(_this22._idParamAngleZ, 0, 10, 5.5345, .5)), t.pushBack(new yt(_this22._idParamBodyAngleX, 0, 4, 15.5345, .5)), t.pushBack(new yt($.getIdManager().getId(ot.ParamBreath), .5, .5, 3.2345, 1)), _this22._breath.setParameters(t), _this22._state = hs.LoadUserData, o();
        },
        o = function o() {
          if ('' != _this22._modelSetting.getUserDataFile()) {
            var _t110 = _this22._modelSetting.getUserDataFile();
            fetch("".concat(_this22._modelHomeDir).concat(_t110)).then(function (e) {
              return e.ok ? e.arrayBuffer() : e.status >= 400 ? (b("Failed to load file ".concat(_this22._modelHomeDir).concat(_t110)), new ArrayBuffer(0)) : void 0;
            }).then(function (t) {
              _this22.loadUserData(t, t.byteLength), _this22._state = hs.SetupEyeBlinkIds, l();
            }), _this22._state = hs.WaitLoadUserData;
          } else {
            _this22._state = hs.SetupEyeBlinkIds, l();
          }
        },
        l = function l() {
          var t = _this22._modelSetting.getEyeBlinkParameterCount();
          for (var _e109 = 0; _e109 < t; ++_e109) _this22._eyeBlinkIds.pushBack(_this22._modelSetting.getEyeBlinkParameterId(_e109));
          _this22._state = hs.SetupLipSyncIds, h();
        },
        h = function h() {
          var t = _this22._modelSetting.getLipSyncParameterCount();
          for (var _e110 = 0; _e110 < t; ++_e110) _this22._lipSyncIds.pushBack(_this22._modelSetting.getLipSyncParameterId(_e110));
          _this22._state = hs.SetupLayout, u();
        },
        u = function u() {
          var t = new I();
          null != _this22._modelSetting && null != _this22._modelMatrix ? (_this22._modelSetting.getLayoutMap(t), _this22._modelMatrix.setupFromLayout(t), _this22._state = hs.LoadMotion, g()) : b('Failed to setupLayout().');
        },
        g = function g() {
          _this22._state = hs.WaitLoadMotion, _this22._model.saveParameters(), _this22._allMotionCount = 0, _this22._motionCount = 0;
          var t = [],
            e = _this22._modelSetting.getMotionGroupCount();
          for (var _i65 = 0; _i65 < e; _i65++) t[_i65] = _this22._modelSetting.getMotionGroupName(_i65), _this22._allMotionCount += _this22._modelSetting.getMotionCount(t[_i65]);
          for (var _i66 = 0; _i66 < e; _i66++) _this22.preLoadMotionGroup(t[_i66]);
          0 == e && (_this22._state = hs.LoadTexture, _this22._motionManager.stopAllMotions(), _this22._updating = !1, _this22._initialized = !0, _this22.createRenderer(), _this22.setupTextures(), _this22.getRenderer().startUp(_this22._subdelegate.getGlManager().getGl()));
        };
    }
  }, {
    key: "setupTextures",
    value: function setupTextures() {
      var _this23 = this;
      var t = !0;
      if (this._state == hs.LoadTexture) {
        var _e111 = this._modelSetting.getTextureCount();
        var _loop2 = function _loop2(_i67) {
          if ('' == _this23._modelSetting.getTextureFileName(_i67)) {
            console.log('getTextureFileName null');
            return 1; // continue
          }
          var s = _this23._modelSetting.getTextureFileName(_i67);
          s = _this23._modelHomeDir + s;
          var r = function r(t) {
            _this23.getRenderer().bindTexture(_i67, t.id), _this23._textureCount++, _this23._textureCount >= _e111 && (_this23._state = hs.CompleteSetup);
          };
          _this23._subdelegate.getTextureManager().createTextureFromPngFile(s, t, r), _this23.getRenderer().setIsPremultipliedAlpha(t);
        };
        for (var _i67 = 0; _i67 < _e111; _i67++) {
          if (_loop2(_i67)) continue;
        }
        this._state = hs.WaitLoadTexture;
      }
    }
  }, {
    key: "reloadRenderer",
    value: function reloadRenderer() {
      this.deleteRenderer(), this.createRenderer(), this.setupTextures();
    }
  }, {
    key: "update",
    value: function update() {
      if (this._state != hs.CompleteSetup) return;
      var t = at.getDeltaTime();
      this._userTimeSeconds += t, this._dragManager.update(t), this._dragX = this._dragManager.getX(), this._dragY = this._dragManager.getY();
      var e = !1;
      if (this._model.loadParameters(), this._motionManager.isFinished() ? this.startRandomMotion('Idle', 1) : e = this._motionManager.updateMotion(this._model, t), this._model.saveParameters(), e || null != this._eyeBlink && this._eyeBlink.updateParameters(this._model, t), null != this._expressionManager && this._expressionManager.updateMotion(this._model, t), this._model.addParameterValueById(this._idParamAngleX, 30 * this._dragX), this._model.addParameterValueById(this._idParamAngleY, 30 * this._dragY), this._model.addParameterValueById(this._idParamAngleZ, this._dragX * this._dragY * -30), this._model.addParameterValueById(this._idParamBodyAngleX, 10 * this._dragX), this._model.addParameterValueById(this._idParamEyeBallX, this._dragX), this._model.addParameterValueById(this._idParamEyeBallY, this._dragY), null != this._breath && this._breath.updateParameters(this._model, t), null != this._physics && this._physics.evaluate(this._model, t), this._lipsync) {
        var _e112 = 0;
        this._wavFileHandler.update(t), _e112 = this._wavFileHandler.getRms();
        for (var _t111 = 0; _t111 < this._lipSyncIds.getSize(); ++_t111) this._model.addParameterValueById(this._lipSyncIds.at(_t111), _e112, .8);
      }
      null != this._pose && this._pose.updateParameters(this._model, t), this._model.update();
    }
  }, {
    key: "startMotion",
    value: function startMotion(t, e, i, s, r) {
      var _this24 = this;
      if (3 == i) {
        this._motionManager.setReservePriority(i);
      } else if (!this._motionManager.reserveMotion(i)) return this._debugMode && at.printMessage('[APP]can\'t start motion.'), Yt;
      var a = this._modelSetting.getMotionFileName(t, e),
        n = "".concat(t, "_").concat(e);
      var o = this._motions.getValue(n),
        l = !1;
      if (null == o) {
        if (fetch("".concat(this._modelHomeDir).concat(a)).then(function (t) {
          return t.ok ? t.arrayBuffer() : t.status >= 400 ? (b("Failed to load file ".concat(_this24._modelHomeDir).concat(a)), new ArrayBuffer(0)) : void 0;
        }).then(function (i) {
          o = _this24.loadMotion(i, i.byteLength, null, s, r, _this24._modelSetting, t, e, _this24._motionConsistency);
        }), !o) {
          return b('Can\'t start motion {0} .', a), this._motionManager.setReservePriority(0), Yt;
        }
        o.setEffectIds(this._eyeBlinkIds, this._lipSyncIds), l = !0;
      } else {
        o.setBeganMotionHandler(r), o.setFinishedMotionHandler(s);
      }
      var h = this._modelSetting.getMotionSoundFileName(t, e);
      if (0 != h.localeCompare('')) {
        var _t112 = h;
        _t112 = this._modelHomeDir + _t112, this._wavFileHandler.start(_t112);
      }
      return this._debugMode && at.printMessage("[APP]start motion: [".concat(t, "_").concat(e, "]")), this._motionManager.startMotionPriority(o, l, i);
    }
  }, {
    key: "startRandomMotion",
    value: function startRandomMotion(t, e, i, s) {
      if (0 == this._modelSetting.getMotionCount(t)) return Yt;
      var r = Math.floor(Math.random() * this._modelSetting.getMotionCount(t));
      return this.startMotion(t, r, e, i, s);
    }
  }, {
    key: "setExpression",
    value: function setExpression(t) {
      var e = this._expressions.getValue(t);
      this._debugMode && at.printMessage("[APP]expression: [".concat(t, "]")), null != e ? this._expressionManager.startMotion(e, !1) : this._debugMode && at.printMessage("[APP]expression[".concat(t, "] is null"));
    }
  }, {
    key: "setRandomExpression",
    value: function setRandomExpression() {
      if (0 == this._expressions.getSize()) return;
      var t = Math.floor(Math.random() * this._expressions.getSize());
      for (var _e113 = 0; _e113 < this._expressions.getSize(); _e113++) {
        if (_e113 == t) {
          var _t113 = this._expressions._keyValues[_e113].first;
          return void this.setExpression(_t113);
        }
      }
    }
  }, {
    key: "motionEventFired",
    value: function motionEventFired(t) {
      M('{0} is fired on LAppModel!!', t.s);
    }
  }, {
    key: "hitTest",
    value: function hitTest(t, e, i) {
      if (this._opacity < 1) return !1;
      var s = this._modelSetting.getHitAreasCount();
      for (var _r23 = 0; _r23 < s; _r23++) {
        if (this._modelSetting.getHitAreaName(_r23) == t) {
          var _t114 = this._modelSetting.getHitAreaId(_r23);
          return this.isHit(_t114, e, i);
        }
      }
      return !1;
    }
  }, {
    key: "preLoadMotionGroup",
    value: function preLoadMotionGroup(t) {
      var _this25 = this;
      var _loop3 = function _loop3(_e114) {
        var i = _this25._modelSetting.getMotionFileName(t, _e114),
          s = "".concat(t, "_").concat(_e114);
        _this25._debugMode && at.printMessage("[APP]load motion: ".concat(i, " => [").concat(s, "]")), fetch("".concat(_this25._modelHomeDir).concat(i)).then(function (t) {
          return t.ok ? t.arrayBuffer() : t.status >= 400 ? (b("Failed to load file ".concat(_this25._modelHomeDir).concat(i)), new ArrayBuffer(0)) : void 0;
        }).then(function (i) {
          var r = _this25.loadMotion(i, i.byteLength, s, null, null, _this25._modelSetting, t, _e114, _this25._motionConsistency);
          null != r ? (r.setEffectIds(_this25._eyeBlinkIds, _this25._lipSyncIds), null != _this25._motions.getValue(s) && Lt.delete(_this25._motions.getValue(s)), _this25._motions.setValue(s, r), _this25._motionCount++) : _this25._allMotionCount--, _this25._motionCount >= _this25._allMotionCount && (_this25._state = hs.LoadTexture, _this25._motionManager.stopAllMotions(), _this25._updating = !1, _this25._initialized = !0, _this25.createRenderer(), _this25.setupTextures(), _this25.getRenderer().startUp(_this25._subdelegate.getGlManager().getGl()));
        });
      };
      for (var _e114 = 0; _e114 < this._modelSetting.getMotionCount(t); _e114++) {
        _loop3(_e114);
      }
    }
  }, {
    key: "releaseMotions",
    value: function releaseMotions() {
      this._motions.clear();
    }
  }, {
    key: "releaseExpressions",
    value: function releaseExpressions() {
      this._expressions.clear();
    }
  }, {
    key: "doDraw",
    value: function doDraw() {
      if (null == this._model) return;
      var t = this._subdelegate.getCanvas(),
        e = [0, 0, t.width, t.height];
      this.getRenderer().setRenderState(this._subdelegate.getFrameBuffer(), e), this.getRenderer().drawModel();
    }
  }, {
    key: "draw",
    value: function draw(t) {
      null != this._model && this._state == hs.CompleteSetup && (t.multiplyByMatrix(this._modelMatrix), this.getRenderer().setMvpMatrix(t), this.doDraw());
    }
  }, {
    key: "hasMocConsistencyFromFile",
    value: function () {
      var _hasMocConsistencyFromFile = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee3() {
        var _t115, _e115, _i68;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee3$(_context3) {
          while (1) switch (_context3.prev = _context3.next) {
            case 0:
              if (!(C(this._modelSetting.getModelFileName().localeCompare('')), '' != this._modelSetting.getModelFileName())) {
                _context3.next = 9;
                break;
              }
              _t115 = this._modelSetting.getModelFileName();
              _context3.next = 4;
              return fetch("".concat(this._modelHomeDir).concat(_t115));
            case 4:
              _e115 = _context3.sent;
              _context3.next = 7;
              return _e115.arrayBuffer();
            case 7:
              _i68 = _context3.sent;
              return _context3.abrupt("return", (this._consistency = Ji.hasMocConsistency(_i68), this._consistency ? M('Consistent MOC3.') : M('Inconsistent MOC3.'), this._consistency));
            case 9:
              at.printMessage('Model data does not exist.');
            case 10:
            case "end":
              return _context3.stop();
          }
        }, _callee3, this);
      }));
      function hasMocConsistencyFromFile() {
        return _hasMocConsistencyFromFile.apply(this, arguments);
      }
      return hasMocConsistencyFromFile;
    }()
  }, {
    key: "setSubdelegate",
    value: function setSubdelegate(t) {
      this._subdelegate = t;
    }
  }]);
  return gs;
}(rs);
var ds = /*#__PURE__*/function () {
  function ds() {
    (0,classCallCheck/* default */.A)(this, ds);
    this.beganMotion = function (t) {
      at.printMessage('Motion Began:'), console.log(t);
    }, this.finishedMotion = function (t) {
      at.printMessage('Motion Finished:'), console.log(t);
    }, this._subdelegate = null, this._viewMatrix = new c(), this._models = new e(), this._sceneIndex = 0;
  }
  (0,createClass/* default */.A)(ds, [{
    key: "releaseAllModel",
    value: function releaseAllModel() {
      this._models.clear();
    }
  }, {
    key: "onDrag",
    value: function onDrag(t, e) {
      var i = this._models.at(0);
      i && i.setDragging(t, e);
    }
  }, {
    key: "onTap",
    value: function onTap(t, e) {
      var i = this._models.at(0);
      i.hitTest('Head', t, e) ? i.setRandomExpression() : i.hitTest(st, t, e) && i.startRandomMotion('TapBody', 2, this.finishedMotion, this.beganMotion);
    }
  }, {
    key: "onUpdate",
    value: function onUpdate() {
      var _this$_subdelegate$ge = this._subdelegate.getCanvas(),
        t = _this$_subdelegate$ge.width,
        e = _this$_subdelegate$ge.height,
        i = new c(),
        s = this._models.at(0);
      s.getModel() && (s.getModel().getCanvasWidth() > 1 && t < e ? (s.getModelMatrix().setWidth(2), i.scale(1, t / e)) : i.scale(e / t, 1), null != this._viewMatrix && i.multiplyByMatrix(this._viewMatrix)), s.update(), s.draw(i);
    }
  }, {
    key: "nextScene",
    value: function nextScene() {
      var t = (this._sceneIndex + 1) % it;
      this.changeScene(t);
    }
  }, {
    key: "changeScene",
    value: function changeScene(t) {
      this._sceneIndex = t;
      var e = tt + et[t] + '/';
      var i = et[t];
      i += '.model3.json', this.releaseAllModel();
      var s = new gs();
      s.setSubdelegate(this._subdelegate), s.loadAssets(e, i), this._models.pushBack(s);
    }
  }, {
    key: "setViewMatrix",
    value: function setViewMatrix(t) {
      for (var _e116 = 0; _e116 < 16; _e116++) this._viewMatrix.getArray()[_e116] = t.getArray()[_e116];
    }
  }, {
    key: "addModel",
    value: function addModel() {
      var t = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
      this._sceneIndex = t, this.changeScene(this._sceneIndex);
    }
  }, {
    key: "release",
    value: function release() {}
  }, {
    key: "initialize",
    value: function initialize(t) {
      this._subdelegate = t, this.changeScene(this._sceneIndex);
    }
  }]);
  return ds;
}();
var _s = /*#__PURE__*/function () {
  function _s() {
    (0,classCallCheck/* default */.A)(this, _s);
    this._textures = new e();
  }
  (0,createClass/* default */.A)(_s, [{
    key: "release",
    value: function release() {
      for (var _t116 = this._textures.begin(); _t116.notEqual(this._textures.end()); _t116.preIncrement()) this._glManager.getGl().deleteTexture(_t116.ptr().id);
      this._textures = null;
    }
  }, {
    key: "createTextureFromPngFile",
    value: function createTextureFromPngFile(t, e, i) {
      var _this26 = this;
      var _loop4 = function _loop4(_s48) {
          if (_s48.ptr().fileName == t && _s48.ptr().usePremultply == e) return {
            v: (_s48.ptr().img = new Image(), _s48.ptr().img.addEventListener('load', function () {
              return i(_s48.ptr());
            }, {
              passive: !0
            }), void (_s48.ptr().img.src = t))
          };
        },
        _ret;
      for (var _s48 = this._textures.begin(); _s48.notEqual(this._textures.end()); _s48.preIncrement()) {
        _ret = _loop4(_s48);
        if (_ret) return _ret.v;
      }
      var s = new Image();
      s.addEventListener('load', function () {
        var r = _this26._glManager.getGl().createTexture();
        _this26._glManager.getGl().bindTexture(_this26._glManager.getGl().TEXTURE_2D, r), _this26._glManager.getGl().texParameteri(_this26._glManager.getGl().TEXTURE_2D, _this26._glManager.getGl().TEXTURE_MIN_FILTER, _this26._glManager.getGl().LINEAR_MIPMAP_LINEAR), _this26._glManager.getGl().texParameteri(_this26._glManager.getGl().TEXTURE_2D, _this26._glManager.getGl().TEXTURE_MAG_FILTER, _this26._glManager.getGl().LINEAR), e && _this26._glManager.getGl().pixelStorei(_this26._glManager.getGl().UNPACK_PREMULTIPLY_ALPHA_WEBGL, 1), _this26._glManager.getGl().texImage2D(_this26._glManager.getGl().TEXTURE_2D, 0, _this26._glManager.getGl().RGBA, _this26._glManager.getGl().RGBA, _this26._glManager.getGl().UNSIGNED_BYTE, s), _this26._glManager.getGl().generateMipmap(_this26._glManager.getGl().TEXTURE_2D), _this26._glManager.getGl().bindTexture(_this26._glManager.getGl().TEXTURE_2D, null);
        var a = new cs();
        null != a && (a.fileName = t, a.width = s.width, a.height = s.height, a.id = r, a.img = s, a.usePremultply = e, null != _this26._textures && _this26._textures.pushBack(a)), i(a);
      }, {
        passive: !0
      }), s.src = t;
    }
  }, {
    key: "releaseTextures",
    value: function releaseTextures() {
      for (var _t117 = 0; _t117 < this._textures.getSize(); _t117++) this._glManager.getGl().deleteTexture(this._textures.at(_t117).id), this._textures.set(_t117, null);
      this._textures.clear();
    }
  }, {
    key: "releaseTextureByTexture",
    value: function releaseTextureByTexture(t) {
      for (var _e117 = 0; _e117 < this._textures.getSize(); _e117++) {
        if (this._textures.at(_e117).id == t) {
          this._glManager.getGl().deleteTexture(this._textures.at(_e117).id), this._textures.set(_e117, null), this._textures.remove(_e117);
          break;
        }
      }
    }
  }, {
    key: "releaseTextureByFilePath",
    value: function releaseTextureByFilePath(t) {
      for (var _e118 = 0; _e118 < this._textures.getSize(); _e118++) {
        if (this._textures.at(_e118).fileName == t) {
          this._glManager.getGl().deleteTexture(this._textures.at(_e118).id), this._textures.set(_e118, null), this._textures.remove(_e118);
          break;
        }
      }
    }
  }, {
    key: "setGlManager",
    value: function setGlManager(t) {
      this._glManager = t;
    }
  }]);
  return _s;
}();
var cs = /*#__PURE__*/(0,createClass/* default */.A)(function cs() {
  (0,classCallCheck/* default */.A)(this, cs);
  this.id = null, this.width = 0, this.height = 0;
});
var ms = /*#__PURE__*/function (_c4) {
  (0,inherits/* default */.A)(ms, _c4);
  function ms() {
    var _this27;
    (0,classCallCheck/* default */.A)(this, ms);
    _this27 = (0,callSuper/* default */.A)(this, ms), _this27._screenLeft = 0, _this27._screenRight = 0, _this27._screenTop = 0, _this27._screenBottom = 0, _this27._maxLeft = 0, _this27._maxRight = 0, _this27._maxTop = 0, _this27._maxBottom = 0, _this27._maxScale = 0, _this27._minScale = 0;
    return _this27;
  }
  (0,createClass/* default */.A)(ms, [{
    key: "adjustTranslate",
    value: function adjustTranslate(t, e) {
      this._tr[0] * this._maxLeft + (this._tr[12] + t) > this._screenLeft && (t = this._screenLeft - this._tr[0] * this._maxLeft - this._tr[12]), this._tr[0] * this._maxRight + (this._tr[12] + t) < this._screenRight && (t = this._screenRight - this._tr[0] * this._maxRight - this._tr[12]), this._tr[5] * this._maxTop + (this._tr[13] + e) < this._screenTop && (e = this._screenTop - this._tr[5] * this._maxTop - this._tr[13]), this._tr[5] * this._maxBottom + (this._tr[13] + e) > this._screenBottom && (e = this._screenBottom - this._tr[5] * this._maxBottom - this._tr[13]);
      var i = new Float32Array([1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, t, e, 0, 1]);
      c.multiply(i, this._tr, this._tr);
    }
  }, {
    key: "adjustScale",
    value: function adjustScale(t, e, i) {
      var s = this.getMaxScale(),
        r = this.getMinScale(),
        a = i * this._tr[0];
      a < r ? this._tr[0] > 0 && (i = r / this._tr[0]) : a > s && this._tr[0] > 0 && (i = s / this._tr[0]);
      var n = new Float32Array([1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, t, e, 0, 1]),
        o = new Float32Array([i, 0, 0, 0, 0, i, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1]),
        l = new Float32Array([1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, -t, -e, 0, 1]);
      c.multiply(l, this._tr, this._tr), c.multiply(o, this._tr, this._tr), c.multiply(n, this._tr, this._tr);
    }
  }, {
    key: "setScreenRect",
    value: function setScreenRect(t, e, i, s) {
      this._screenLeft = t, this._screenRight = e, this._screenBottom = i, this._screenTop = s;
    }
  }, {
    key: "setMaxScreenRect",
    value: function setMaxScreenRect(t, e, i, s) {
      this._maxLeft = t, this._maxRight = e, this._maxTop = s, this._maxBottom = i;
    }
  }, {
    key: "setMaxScale",
    value: function setMaxScale(t) {
      this._maxScale = t;
    }
  }, {
    key: "setMinScale",
    value: function setMinScale(t) {
      this._minScale = t;
    }
  }, {
    key: "getMaxScale",
    value: function getMaxScale() {
      return this._maxScale;
    }
  }, {
    key: "getMinScale",
    value: function getMinScale() {
      return this._minScale;
    }
  }, {
    key: "isMaxScale",
    value: function isMaxScale() {
      return this.getScaleX() >= this._maxScale;
    }
  }, {
    key: "isMinScale",
    value: function isMinScale() {
      return this.getScaleX() <= this._minScale;
    }
  }, {
    key: "getScreenLeft",
    value: function getScreenLeft() {
      return this._screenLeft;
    }
  }, {
    key: "getScreenRight",
    value: function getScreenRight() {
      return this._screenRight;
    }
  }, {
    key: "getScreenBottom",
    value: function getScreenBottom() {
      return this._screenBottom;
    }
  }, {
    key: "getScreenTop",
    value: function getScreenTop() {
      return this._screenTop;
    }
  }, {
    key: "getMaxLeft",
    value: function getMaxLeft() {
      return this._maxLeft;
    }
  }, {
    key: "getMaxRight",
    value: function getMaxRight() {
      return this._maxRight;
    }
  }, {
    key: "getMaxBottom",
    value: function getMaxBottom() {
      return this._maxBottom;
    }
  }, {
    key: "getMaxTop",
    value: function getMaxTop() {
      return this._maxTop;
    }
  }]);
  return ms;
}(c);
!function (t) {
  t.CubismViewMatrix = ms;
}(us || (us = {}));
var ps = /*#__PURE__*/function () {
  function ps(t, e, i, s, r) {
    (0,classCallCheck/* default */.A)(this, ps);
    this._rect = new fs(), this._rect.left = t - .5 * i, this._rect.right = t + .5 * i, this._rect.up = e + .5 * s, this._rect.down = e - .5 * s, this._texture = r, this._vertexBuffer = null, this._uvBuffer = null, this._indexBuffer = null, this._positionLocation = null, this._uvLocation = null, this._textureLocation = null, this._positionArray = null, this._uvArray = null, this._indexArray = null, this._firstDraw = !0;
  }
  (0,createClass/* default */.A)(ps, [{
    key: "release",
    value: function release() {
      this._rect = null;
      var t = this._subdelegate.getGlManager().getGl();
      t.deleteTexture(this._texture), this._texture = null, t.deleteBuffer(this._uvBuffer), this._uvBuffer = null, t.deleteBuffer(this._vertexBuffer), this._vertexBuffer = null, t.deleteBuffer(this._indexBuffer), this._indexBuffer = null;
    }
  }, {
    key: "getTexture",
    value: function getTexture() {
      return this._texture;
    }
  }, {
    key: "render",
    value: function render(t) {
      if (null == this._texture) return;
      var e = this._subdelegate.getGlManager().getGl();
      if (this._firstDraw) {
        this._positionLocation = e.getAttribLocation(t, 'position'), e.enableVertexAttribArray(this._positionLocation), this._uvLocation = e.getAttribLocation(t, 'uv'), e.enableVertexAttribArray(this._uvLocation), this._textureLocation = e.getUniformLocation(t, 'texture'), e.uniform1i(this._textureLocation, 0), this._uvArray = new Float32Array([1, 0, 0, 0, 0, 1, 1, 1]), this._uvBuffer = e.createBuffer();
        {
          var _t118 = this._subdelegate.getCanvas().width,
            _i69 = this._subdelegate.getCanvas().height;
          this._positionArray = new Float32Array([(this._rect.right - .5 * _t118) / (.5 * _t118), (this._rect.up - .5 * _i69) / (.5 * _i69), (this._rect.left - .5 * _t118) / (.5 * _t118), (this._rect.up - .5 * _i69) / (.5 * _i69), (this._rect.left - .5 * _t118) / (.5 * _t118), (this._rect.down - .5 * _i69) / (.5 * _i69), (this._rect.right - .5 * _t118) / (.5 * _t118), (this._rect.down - .5 * _i69) / (.5 * _i69)]), this._vertexBuffer = e.createBuffer();
        }
        this._indexArray = new Uint16Array([0, 1, 2, 3, 2, 0]), this._indexBuffer = e.createBuffer(), this._firstDraw = !1;
      }
      e.bindBuffer(e.ARRAY_BUFFER, this._uvBuffer), e.bufferData(e.ARRAY_BUFFER, this._uvArray, e.STATIC_DRAW), e.vertexAttribPointer(this._uvLocation, 2, e.FLOAT, !1, 0, 0), e.bindBuffer(e.ARRAY_BUFFER, this._vertexBuffer), e.bufferData(e.ARRAY_BUFFER, this._positionArray, e.STATIC_DRAW), e.vertexAttribPointer(this._positionLocation, 2, e.FLOAT, !1, 0, 0), e.bindBuffer(e.ELEMENT_ARRAY_BUFFER, this._indexBuffer), e.bufferData(e.ELEMENT_ARRAY_BUFFER, this._indexArray, e.DYNAMIC_DRAW), e.bindTexture(e.TEXTURE_2D, this._texture), e.drawElements(e.TRIANGLES, this._indexArray.length, e.UNSIGNED_SHORT, 0);
    }
  }, {
    key: "isHit",
    value: function isHit(t, e) {
      var _this$_subdelegate$ge2 = this._subdelegate.getCanvas(),
        i = _this$_subdelegate$ge2.height,
        s = i - e;
      return t >= this._rect.left && t <= this._rect.right && s <= this._rect.up && s >= this._rect.down;
    }
  }, {
    key: "setSubdelegate",
    value: function setSubdelegate(t) {
      this._subdelegate = t;
    }
  }]);
  return ps;
}();
var fs = /*#__PURE__*/(0,createClass/* default */.A)(function fs() {
  (0,classCallCheck/* default */.A)(this, fs);
});
var ys = /*#__PURE__*/function () {
  function ys() {
    (0,classCallCheck/* default */.A)(this, ys);
    this._startX = 0, this._startY = 0, this._lastX = 0, this._lastY = 0, this._lastX1 = 0, this._lastY1 = 0, this._lastX2 = 0, this._lastY2 = 0, this._lastTouchDistance = 0, this._deltaX = 0, this._deltaY = 0, this._scale = 1, this._touchSingle = !1, this._flipAvailable = !1;
  }
  (0,createClass/* default */.A)(ys, [{
    key: "getCenterX",
    value: function getCenterX() {
      return this._lastX;
    }
  }, {
    key: "getCenterY",
    value: function getCenterY() {
      return this._lastY;
    }
  }, {
    key: "getDeltaX",
    value: function getDeltaX() {
      return this._deltaX;
    }
  }, {
    key: "getDeltaY",
    value: function getDeltaY() {
      return this._deltaY;
    }
  }, {
    key: "getStartX",
    value: function getStartX() {
      return this._startX;
    }
  }, {
    key: "getStartY",
    value: function getStartY() {
      return this._startY;
    }
  }, {
    key: "getScale",
    value: function getScale() {
      return this._scale;
    }
  }, {
    key: "getX",
    value: function getX() {
      return this._lastX;
    }
  }, {
    key: "getY",
    value: function getY() {
      return this._lastY;
    }
  }, {
    key: "getX1",
    value: function getX1() {
      return this._lastX1;
    }
  }, {
    key: "getY1",
    value: function getY1() {
      return this._lastY1;
    }
  }, {
    key: "getX2",
    value: function getX2() {
      return this._lastX2;
    }
  }, {
    key: "getY2",
    value: function getY2() {
      return this._lastY2;
    }
  }, {
    key: "isSingleTouch",
    value: function isSingleTouch() {
      return this._touchSingle;
    }
  }, {
    key: "isFlickAvailable",
    value: function isFlickAvailable() {
      return this._flipAvailable;
    }
  }, {
    key: "disableFlick",
    value: function disableFlick() {
      this._flipAvailable = !1;
    }
  }, {
    key: "touchesBegan",
    value: function touchesBegan(t, e) {
      this._lastX = t, this._lastY = e, this._startX = t, this._startY = e, this._lastTouchDistance = -1, this._flipAvailable = !0, this._touchSingle = !0;
    }
  }, {
    key: "touchesMoved",
    value: function touchesMoved(t, e) {
      this._lastX = t, this._lastY = e, this._lastTouchDistance = -1, this._touchSingle = !0;
    }
  }, {
    key: "getFlickDistance",
    value: function getFlickDistance() {
      return this.calculateDistance(this._startX, this._startY, this._lastX, this._lastY);
    }
  }, {
    key: "calculateDistance",
    value: function calculateDistance(t, e, i, s) {
      return Math.sqrt((t - i) * (t - i) + (e - s) * (e - s));
    }
  }, {
    key: "calculateMovingAmount",
    value: function calculateMovingAmount(t, e) {
      if (t > 0 != e > 0) return 0;
      var i = t > 0 ? 1 : -1,
        s = Math.abs(t),
        r = Math.abs(e);
      return i * (s < r ? s : r);
    }
  }]);
  return ys;
}();
var Ss = /*#__PURE__*/function () {
  function Ss() {
    (0,classCallCheck/* default */.A)(this, Ss);
    this._programId = null, this._back = null, this._gear = null, this._touchManager = new ys(), this._deviceToScreen = new c(), this._viewMatrix = new ms();
  }
  (0,createClass/* default */.A)(Ss, [{
    key: "initialize",
    value: function initialize(t) {
      this._subdelegate = t;
      var _t$getCanvas = t.getCanvas(),
        e = _t$getCanvas.width,
        i = _t$getCanvas.height,
        s = e / i,
        r = -s,
        a = s;
      if (this._viewMatrix.setScreenRect(r, a, -1, 1), this._viewMatrix.scale(1, 1), this._deviceToScreen.loadIdentity(), e > i) {
        var _t119 = Math.abs(a - r);
        this._deviceToScreen.scaleRelative(_t119 / e, -_t119 / e);
      } else {
        var _t120 = Math.abs(2);
        this._deviceToScreen.scaleRelative(_t120 / i, -_t120 / i);
      }
      this._deviceToScreen.translateRelative(.5 * -e, .5 * -i), this._viewMatrix.setMaxScale(2), this._viewMatrix.setMinScale(.8), this._viewMatrix.setMaxScreenRect(-2, 2, -2, 2);
    }
  }, {
    key: "release",
    value: function release() {
      this._viewMatrix = null, this._touchManager = null, this._deviceToScreen = null, this._gear.release(), this._gear = null, this._back.release(), this._back = null, this._subdelegate.getGlManager().getGl().deleteProgram(this._programId), this._programId = null;
    }
  }, {
    key: "render",
    value: function render() {
      this._subdelegate.getGlManager().getGl().useProgram(this._programId), this._back && this._back.render(this._programId), this._gear && this._gear.render(this._programId), this._subdelegate.getGlManager().getGl().flush();
      var t = this._subdelegate.getLive2DManager();
      null != t && (t.setViewMatrix(this._viewMatrix), t.onUpdate());
    }
  }, {
    key: "initializeSprite",
    value: function initializeSprite() {
      var _this28 = this;
      var t = this._subdelegate.getCanvas().width,
        e = this._subdelegate.getCanvas().height,
        i = this._subdelegate.getTextureManager(),
        s = tt;
      var r = '';
      r = 'back_class_normal.png';
      i.createTextureFromPngFile(s + r, !1, function (i) {
        var s = .5 * t,
          r = .5 * e,
          a = 2 * i.width,
          n = .95 * e;
        _this28._back = new ps(s, r, a, n, i.id), _this28._back.setSubdelegate(_this28._subdelegate);
      }), r = 'icon_gear.png';
      i.createTextureFromPngFile(s + r, !1, function (i) {
        var s = t - .5 * i.width,
          r = e - .5 * i.height,
          a = i.width,
          n = i.height;
        _this28._gear = new ps(s, r, a, n, i.id), _this28._gear.setSubdelegate(_this28._subdelegate);
      }), null == this._programId && (this._programId = this._subdelegate.createShader());
    }
  }, {
    key: "onTouchesBegan",
    value: function onTouchesBegan(t, e) {
      this._touchManager.touchesBegan(t * window.devicePixelRatio, e * window.devicePixelRatio);
    }
  }, {
    key: "onTouchesMoved",
    value: function onTouchesMoved(t, e) {
      var i = t * window.devicePixelRatio,
        s = e * window.devicePixelRatio,
        r = this._subdelegate.getLive2DManager(),
        a = this.transformViewX(this._touchManager.getX()),
        n = this.transformViewY(this._touchManager.getY());
      this._touchManager.touchesMoved(i, s), r.onDrag(a, n);
    }
  }, {
    key: "onTouchesEnded",
    value: function onTouchesEnded(t, e) {
      var i = t * window.devicePixelRatio,
        s = e * window.devicePixelRatio,
        r = this._subdelegate.getLive2DManager();
      r.onDrag(0, 0);
      var a = this.transformViewX(i),
        n = this.transformViewY(s);
      r.onTap(a, n), this._gear.isHit(i, s) && r.nextScene();
    }
  }, {
    key: "transformViewX",
    value: function transformViewX(t) {
      var e = this._deviceToScreen.transformX(t);
      return this._viewMatrix.invertTransformX(e);
    }
  }, {
    key: "transformViewY",
    value: function transformViewY(t) {
      var e = this._deviceToScreen.transformY(t);
      return this._viewMatrix.invertTransformY(e);
    }
  }, {
    key: "transformScreenX",
    value: function transformScreenX(t) {
      return this._deviceToScreen.transformX(t);
    }
  }, {
    key: "transformScreenY",
    value: function transformScreenY(t) {
      return this._deviceToScreen.transformY(t);
    }
  }]);
  return Ss;
}();
var Cs = /*#__PURE__*/function () {
  function Cs() {
    (0,classCallCheck/* default */.A)(this, Cs);
    this._canvas = null, this._glManager = new nt(), this._textureManager = new _s(), this._live2dManager = new ds(), this._view = new Ss(), this._frameBuffer = null, this._captured = !1;
  }
  (0,createClass/* default */.A)(Cs, [{
    key: "release",
    value: function release() {
      this._resizeObserver.unobserve(this._canvas), this._resizeObserver.disconnect(), this._resizeObserver = null, this._live2dManager.release(), this._live2dManager = null, this._view.release(), this._view = null, this._textureManager.release(), this._textureManager = null, this._glManager.release(), this._glManager = null;
    }
  }, {
    key: "initialize",
    value: function initialize(t) {
      var _this29 = this;
      if (!this._glManager.initialize(t)) return !1;
      this._canvas = t, this.resizeCanvas(), this._textureManager.setGlManager(this._glManager);
      var e = this._glManager.getGl();
      return this._frameBuffer || (this._frameBuffer = e.getParameter(e.FRAMEBUFFER_BINDING)), e.enable(e.BLEND), e.blendFunc(e.SRC_ALPHA, e.ONE_MINUS_SRC_ALPHA), this._view.initialize(this), this._view.initializeSprite(), this._live2dManager.initialize(this), this._resizeObserver = new ResizeObserver(function (t, e) {
        return _this29.resizeObserverCallback.call(_this29, t, e);
      }), this._resizeObserver.observe(this._canvas), !0;
    }
  }, {
    key: "onResize",
    value: function onResize() {
      this.resizeCanvas(), this._view.initialize(this), this._view.initializeSprite();
    }
  }, {
    key: "resizeObserverCallback",
    value: function resizeObserverCallback(t, e) {
      this._needResize = !0;
    }
  }, {
    key: "update",
    value: function update() {
      if (this._glManager.getGl().isContextLost()) return;
      this._needResize && (this.onResize(), this._needResize = !1);
      var t = this._glManager.getGl();
      t.clearColor(0, 0, 0, 1), t.enable(t.DEPTH_TEST), t.depthFunc(t.LEQUAL), t.clear(t.COLOR_BUFFER_BIT | t.DEPTH_BUFFER_BIT), t.clearDepth(1), t.enable(t.BLEND), t.blendFunc(t.SRC_ALPHA, t.ONE_MINUS_SRC_ALPHA), this._view.render();
    }
  }, {
    key: "createShader",
    value: function createShader() {
      var t = this._glManager.getGl(),
        e = t.createShader(t.VERTEX_SHADER);
      if (null == e) return at.printMessage('failed to create vertexShader'), null;
      t.shaderSource(e, 'precision mediump float;attribute vec3 position;attribute vec2 uv;varying vec2 vuv;void main(void){   gl_Position = vec4(position, 1.0);   vuv = uv;}'), t.compileShader(e);
      var i = t.createShader(t.FRAGMENT_SHADER);
      if (null == i) return at.printMessage('failed to create fragmentShader'), null;
      t.shaderSource(i, 'precision mediump float;varying vec2 vuv;uniform sampler2D texture;void main(void){   gl_FragColor = texture2D(texture, vuv);}'), t.compileShader(i);
      var s = t.createProgram();
      return t.attachShader(s, e), t.attachShader(s, i), t.deleteShader(e), t.deleteShader(i), t.linkProgram(s), t.useProgram(s), s;
    }
  }, {
    key: "getTextureManager",
    value: function getTextureManager() {
      return this._textureManager;
    }
  }, {
    key: "getFrameBuffer",
    value: function getFrameBuffer() {
      return this._frameBuffer;
    }
  }, {
    key: "getCanvas",
    value: function getCanvas() {
      return this._canvas;
    }
  }, {
    key: "getGlManager",
    value: function getGlManager() {
      return this._glManager;
    }
  }, {
    key: "getLive2DManager",
    value: function getLive2DManager() {
      return this._live2dManager;
    }
  }, {
    key: "resizeCanvas",
    value: function resizeCanvas() {
      this._canvas.width = this._canvas.clientWidth * window.devicePixelRatio, this._canvas.height = this._canvas.clientHeight * window.devicePixelRatio;
      var t = this._glManager.getGl();
      t.viewport(0, 0, t.drawingBufferWidth, t.drawingBufferHeight);
    }
  }, {
    key: "onPointBegan",
    value: function onPointBegan(t, e) {
      if (!this._view) return void at.printMessage('view notfound');
      this._captured = !0;
      var i = t - this._canvas.offsetLeft,
        s = e - this._canvas.offsetTop;
      this._view.onTouchesBegan(i, s);
    }
  }, {
    key: "onPointMoved",
    value: function onPointMoved(t, e) {
      if (!this._captured) return;
      var i = t - this._canvas.offsetLeft,
        s = e - this._canvas.offsetTop;
      this._view.onTouchesMoved(i, s);
    }
  }, {
    key: "onPointEnded",
    value: function onPointEnded(t, e) {
      if (this._captured = !1, !this._view) return void at.printMessage('view notfound');
      var i = t - this._canvas.offsetLeft,
        s = e - this._canvas.offsetTop;
      this._view.onTouchesEnded(i, s);
    }
  }, {
    key: "onTouchCancel",
    value: function onTouchCancel(t, e) {
      if (this._captured = !1, !this._view) return void at.printMessage('view notfound');
      var i = t - this._canvas.offsetLeft,
        s = e - this._canvas.offsetTop;
      this._view.onTouchesEnded(i, s);
    }
  }, {
    key: "isContextLost",
    value: function isContextLost() {
      return this._glManager.getGl().isContextLost();
    }
  }]);
  return Cs;
}();
var xs = null;
var Ms = /*#__PURE__*/function () {
  function Ms() {
    (0,classCallCheck/* default */.A)(this, Ms);
    this._cubismOption = new Z(), this._subdelegates = new e(), this._canvases = new e();
  }
  (0,createClass/* default */.A)(Ms, [{
    key: "onPointerBegan",
    value: function onPointerBegan(t) {
      for (var _e119 = this._subdelegates.begin(); _e119.notEqual(this._subdelegates.end()); _e119.preIncrement()) _e119.ptr().onPointBegan(t.pageX, t.pageY);
    }
  }, {
    key: "onPointerMoved",
    value: function onPointerMoved(t) {
      for (var _e120 = this._subdelegates.begin(); _e120.notEqual(this._subdelegates.end()); _e120.preIncrement()) _e120.ptr().onPointMoved(t.pageX, t.pageY);
    }
  }, {
    key: "onPointerEnded",
    value: function onPointerEnded(t) {
      for (var _e121 = this._subdelegates.begin(); _e121.notEqual(this._subdelegates.end()); _e121.preIncrement()) _e121.ptr().onPointEnded(t.pageX, t.pageY);
    }
  }, {
    key: "onPointerCancel",
    value: function onPointerCancel(t) {
      for (var _e122 = this._subdelegates.begin(); _e122.notEqual(this._subdelegates.end()); _e122.preIncrement()) _e122.ptr().onTouchCancel(t.pageX, t.pageY);
    }
  }, {
    key: "onResize",
    value: function onResize() {
      for (var _t121 = 0; _t121 < this._subdelegates.getSize(); _t121++) this._subdelegates.at(_t121).onResize();
    }
  }, {
    key: "run",
    value: function run() {
      var _this30 = this;
      var t = function t() {
        if (null != xs) {
          at.updateTime();
          for (var _t122 = 0; _t122 < _this30._subdelegates.getSize(); _t122++) _this30._subdelegates.at(_t122).update();
          requestAnimationFrame(t);
        }
      };
      t();
    }
  }, {
    key: "release",
    value: function release() {
      this.releaseEventListener(), this.releaseSubdelegates(), $.dispose(), this._cubismOption = null;
    }
  }, {
    key: "releaseEventListener",
    value: function releaseEventListener() {
      document.removeEventListener('pointerup', this.pointBeganEventListener), this.pointBeganEventListener = null, document.removeEventListener('pointermove', this.pointMovedEventListener), this.pointMovedEventListener = null, document.removeEventListener('pointerdown', this.pointEndedEventListener), this.pointEndedEventListener = null, document.removeEventListener('pointerdown', this.pointCancelEventListener), this.pointCancelEventListener = null;
    }
  }, {
    key: "releaseSubdelegates",
    value: function releaseSubdelegates() {
      for (var _t123 = this._subdelegates.begin(); _t123.notEqual(this._subdelegates.end()); _t123.preIncrement()) _t123.ptr().release();
      this._subdelegates.clear(), this._subdelegates = null;
    }
  }, {
    key: "initialize",
    value: function initialize() {
      return this.initializeCubism(), this.initializeSubdelegates(), this.initializeEventListener(), !0;
    }
  }, {
    key: "initializeEventListener",
    value: function initializeEventListener() {
      this.pointBeganEventListener = this.onPointerBegan.bind(this), this.pointMovedEventListener = this.onPointerMoved.bind(this), this.pointEndedEventListener = this.onPointerEnded.bind(this), this.pointCancelEventListener = this.onPointerCancel.bind(this), document.addEventListener('pointerdown', this.pointBeganEventListener, {
        passive: !0
      }), document.addEventListener('pointermove', this.pointMovedEventListener, {
        passive: !0
      }), document.addEventListener('pointerup', this.pointEndedEventListener, {
        passive: !0
      }), document.addEventListener('pointercancel', this.pointCancelEventListener, {
        passive: !0
      });
    }
  }, {
    key: "initializeCubism",
    value: function initializeCubism() {
      at.updateTime(), this._cubismOption.logFunction = at.printMessage, this._cubismOption.loggingLevel = rt, $.startUp(this._cubismOption), $.initialize();
    }
  }, {
    key: "initializeSubdelegates",
    value: function initializeSubdelegates() {
      var t = 100;
      t = 100, this._canvases.prepareCapacity(1), this._subdelegates.prepareCapacity(1);
      for (var _t124 = 0; _t124 < 1; _t124++) {
        var _t125 = document.createElement('canvas');
        this._canvases.pushBack(_t125), _t125.style.width = '100vw', _t125.style.height = '100vh', document.body.appendChild(_t125);
      }
      for (var _t126 = 0; _t126 < this._canvases.getSize(); _t126++) {
        var _e123 = new Cs();
        _e123.initialize(this._canvases.at(_t126)), this._subdelegates.pushBack(_e123);
      }
      for (var _t127 = 0; _t127 < 1; _t127++) this._subdelegates.at(_t127).isContextLost() && b("The context for Canvas at index ".concat(_t127, " was lost, possibly because the acquisition limit for WebGLRenderingContext was reached."));
    }
  }], [{
    key: "getInstance",
    value: function getInstance() {
      return null == xs && (xs = new Ms()), xs;
    }
  }, {
    key: "releaseInstance",
    value: function releaseInstance() {
      null != xs && xs.release(), xs = null;
    }
  }]);
  return Ms;
}();
at.printMessage = function () {};
var vs = /*#__PURE__*/function (_Cs) {
  (0,inherits/* default */.A)(vs, _Cs);
  function vs() {
    (0,classCallCheck/* default */.A)(this, vs);
    return (0,callSuper/* default */.A)(this, vs, arguments);
  }
  (0,createClass/* default */.A)(vs, [{
    key: "initialize",
    value: function initialize(t) {
      var _this31 = this;
      if (!this._glManager.initialize(t)) return !1;
      this._canvas = t, this.resizeCanvas(), this._textureManager.setGlManager(this._glManager);
      var e = this._glManager.getGl();
      return this._frameBuffer || (this._frameBuffer = e.getParameter(e.FRAMEBUFFER_BINDING)), e.enable(e.BLEND), e.blendFunc(e.SRC_ALPHA, e.ONE_MINUS_SRC_ALPHA), this._view.initialize(this), this._view._gear = {
        render: function render() {},
        isHit: function isHit() {},
        release: function release() {}
      }, this._view._back = {
        render: function render() {},
        release: function release() {}
      }, this._live2dManager._subdelegate = this, this._resizeObserver = new window.ResizeObserver(function (t, e) {
        return _this31.resizeObserverCallback.call(_this31, t, e);
      }), this._resizeObserver.observe(this._canvas), !0;
    }
  }, {
    key: "onResize",
    value: function onResize() {
      this.resizeCanvas(), this._view.initialize(this);
    }
  }, {
    key: "update",
    value: function update() {
      if (this._glManager.getGl().isContextLost()) return;
      this._needResize && (this.onResize(), this._needResize = !1);
      var t = this._glManager.getGl();
      t.clearColor(0, 0, 0, 0), t.enable(t.DEPTH_TEST), t.depthFunc(t.LEQUAL), t.clear(t.COLOR_BUFFER_BIT | t.DEPTH_BUFFER_BIT), t.clearDepth(1), t.enable(t.BLEND), t.blendFunc(t.SRC_ALPHA, t.ONE_MINUS_SRC_ALPHA), this._view.render();
    }
  }]);
  return vs;
}(Cs);
var bs = /*#__PURE__*/function (_Ms) {
  (0,inherits/* default */.A)(bs, _Ms);
  function bs() {
    (0,classCallCheck/* default */.A)(this, bs);
    return (0,callSuper/* default */.A)(this, bs, arguments);
  }
  (0,createClass/* default */.A)(bs, [{
    key: "run",
    value: function run() {
      var _this32 = this;
      var t = function t() {
        at.updateTime();
        for (var _t128 = 0; _t128 < _this32._subdelegates.getSize(); _t128++) _this32._subdelegates.at(_t128).update();
        _this32._drawFrameId = window.requestAnimationFrame(t);
      };
      t();
    }
  }, {
    key: "stop",
    value: function stop() {
      this._drawFrameId && (window.cancelAnimationFrame(this._drawFrameId), this._drawFrameId = null);
    }
  }, {
    key: "release",
    value: function release() {
      this.stop(), this.releaseEventListener(), this._subdelegates.clear(), this._cubismOption = null;
    }
  }, {
    key: "transformOffset",
    value: function transformOffset(t) {
      var e = this._subdelegates.at(0),
        i = e.getCanvas().getBoundingClientRect(),
        s = t.pageX - i.left,
        r = t.pageY - i.top,
        a = s * window.devicePixelRatio,
        n = r * window.devicePixelRatio;
      return {
        x: e._view.transformViewX(a),
        y: e._view.transformViewY(n)
      };
    }
  }, {
    key: "onMouseMove",
    value: function onMouseMove(t) {
      var e = this._subdelegates.at(0).getLive2DManager(),
        _this$transformOffset = this.transformOffset(t),
        i = _this$transformOffset.x,
        s = _this$transformOffset.y,
        r = e._models.at(0);
      e.onDrag(i, s), e.onTap(i, s), r.hitTest(st, i, s) && window.dispatchEvent(new Event('live2d:hoverbody'));
    }
  }, {
    key: "onMouseEnd",
    value: function onMouseEnd(t) {
      var e = this._subdelegates.at(0).getLive2DManager(),
        _this$transformOffset2 = this.transformOffset(t),
        i = _this$transformOffset2.x,
        s = _this$transformOffset2.y;
      e.onDrag(0, 0), e.onTap(i, s);
    }
  }, {
    key: "onTap",
    value: function onTap(t) {
      var e = this._subdelegates.at(0).getLive2DManager(),
        _this$transformOffset3 = this.transformOffset(t),
        i = _this$transformOffset3.x,
        s = _this$transformOffset3.y;
      e._models.at(0).hitTest(st, i, s) && window.dispatchEvent(new Event('live2d:tapbody'));
    }
  }, {
    key: "initializeEventListener",
    value: function initializeEventListener() {
      this.mouseMoveEventListener = this.onMouseMove.bind(this), this.mouseEndedEventListener = this.onMouseEnd.bind(this), this.tapEventListener = this.onTap.bind(this), document.addEventListener('mousemove', this.mouseMoveEventListener, {
        passive: !0
      }), document.addEventListener('mouseout', this.mouseEndedEventListener, {
        passive: !0
      }), document.addEventListener('pointerdown', this.tapEventListener, {
        passive: !0
      });
    }
  }, {
    key: "releaseEventListener",
    value: function releaseEventListener() {
      document.removeEventListener("mousemove", this.mouseMoveEventListener, {
        passive: !0
      }), this.mouseMoveEventListener = null, document.removeEventListener("mouseout", this.mouseEndedEventListener, {
        passive: !0
      }), this.mouseEndedEventListener = null, document.removeEventListener("pointerdown", this.tapEventListener, {
        passive: !0
      });
    }
  }, {
    key: "initializeSubdelegates",
    value: function initializeSubdelegates() {
      this._canvases.prepareCapacity(1), this._subdelegates.prepareCapacity(1);
      var e = document.getElementById("live2d");
      this._canvases.pushBack(e), e.style.width = e.width, e.style.height = e.height;
      for (var _e124 = 0; _e124 < this._canvases.getSize(); _e124++) {
        var _i70 = new vs();
        if (!_i70.initialize(this._canvases.at(_e124))) return void waifu_tips.l.error("Failed to initialize AppSubdelegate");
        this._subdelegates.pushBack(_i70);
      }
      for (var _e125 = 0; _e125 < 1; _e125++) this._subdelegates.at(_e125).isContextLost() && waifu_tips.l.error("The context for Canvas at index ".concat(_e125, " was lost, possibly because the acquisition limit for WebGLRenderingContext was reached."));
    }
  }, {
    key: "changeModel",
    value: function changeModel(t) {
      var e = t.split("/"),
        i = e.pop(),
        s = e.join("/") + "/",
        r = this._subdelegates.at(0).getLive2DManager();
      r.releaseAllModel();
      var a = new gs();
      a.setSubdelegate(r._subdelegate), a.loadAssets(s, i), r._models.pushBack(a);
    }
  }, {
    key: "subdelegates",
    get: function get() {
      return this._subdelegates;
    }
  }]);
  return bs;
}(Ms);


/***/ }),

/***/ 5673:
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {


// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  l: function() { return /* binding */ a; }
});

// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.js
var es_symbol = __webpack_require__(2675);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.description.js
var es_symbol_description = __webpack_require__(9463);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.iterator.js
var es_symbol_iterator = __webpack_require__(2259);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.error.cause.js
var es_error_cause = __webpack_require__(6280);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.to-string.js
var es_object_to_string = __webpack_require__(6099);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.iterator.js
var es_string_iterator = __webpack_require__(7764);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.iterator.js
var web_dom_collections_iterator = __webpack_require__(2953);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js
var unsupportedIterableToArray = __webpack_require__(5417);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js








function _createForOfIteratorHelper(o, allowArrayLike) {
  var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
  if (!it) {
    if (Array.isArray(o) || (it = (0,unsupportedIterableToArray/* default */.A)(o)) || allowArrayLike && o && typeof o.length === "number") {
      if (it) o = it;
      var i = 0;
      var F = function F() {};
      return {
        s: F,
        n: function n() {
          if (i >= o.length) return {
            done: true
          };
          return {
            done: false,
            value: o[i++]
          };
        },
        e: function e(_e) {
          throw _e;
        },
        f: F
      };
    }
    throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
  }
  var normalCompletion = true,
    didErr = false,
    err;
  return {
    s: function s() {
      it = it.call(o);
    },
    n: function n() {
      var step = it.next();
      normalCompletion = step.done;
      return step;
    },
    e: function e(_e2) {
      didErr = true;
      err = _e2;
    },
    f: function f() {
      try {
        if (!normalCompletion && it["return"] != null) it["return"]();
      } finally {
        if (didErr) throw err;
      }
    }
  };
}
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/regeneratorRuntime.js
var regeneratorRuntime = __webpack_require__(2946);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js
var asyncToGenerator = __webpack_require__(1362);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js
var classCallCheck = __webpack_require__(1512);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/createClass.js + 2 modules
var createClass = __webpack_require__(5629);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.at.js
var es_array_at = __webpack_require__(8107);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.concat.js
var es_array_concat = __webpack_require__(8706);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.push.js
var es_array_push = __webpack_require__(4114);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.number.constructor.js
var es_number_constructor = __webpack_require__(2892);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.keys.js
var es_object_keys = __webpack_require__(9432);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.exec.js
var es_regexp_exec = __webpack_require__(7495);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.regexp.to-string.js
var es_regexp_to_string = __webpack_require__(8781);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.at-alternative.js
var es_string_at_alternative = __webpack_require__(7357);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.ends-with.js
var es_string_ends_with = __webpack_require__(9449);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.replace.js
var es_string_replace = __webpack_require__(5440);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.dom-collections.for-each.js
var web_dom_collections_for_each = __webpack_require__(3500);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url.js
var web_url = __webpack_require__(3296);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.js
var web_url_search_params = __webpack_require__(8408);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.delete.js
var web_url_search_params_delete = __webpack_require__(4603);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.has.js
var web_url_search_params_has = __webpack_require__(7566);
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.size.js
var web_url_search_params_size = __webpack_require__(8721);
;// CONCATENATED MODULE: ./src/components/waifu-tips.js
























function e(e) {
  return Array.isArray(e) ? e[Math.floor(Math.random() * e.length)] : e;
}
function t(e, t) {
  var s = Math.floor(Math.random() * (e - 1));
  return s >= t ? s + 1 : s;
}
function s(e, t) {
  return new Promise(function (t, s) {
    var o;
    o = document.createElement('script'), o.src = e, o && (o.onload = function () {
      return t(e);
    }, o.onerror = function () {
      return s(e);
    }, document.head.appendChild(o));
  });
}
var o = null;
function i(t, s, i) {
  var n = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : !0;
  var l = parseInt(sessionStorage.getItem('waifu-message-priority'), 10);
  if (isNaN(l) && (l = 0), !t || n && l > i || !n && l >= i) return;
  o && (clearTimeout(o), o = null), t = e(t), sessionStorage.setItem('waifu-message-priority', String(i));
  var a = document.getElementById('waifu-tips');
  a.innerHTML = t, a.classList.add('waifu-tips-active'), o = setTimeout(function () {
    sessionStorage.removeItem('waifu-message-priority'), a.classList.remove('waifu-tips-active');
  }, s);
}
function n(e) {
  for (var _len = arguments.length, t = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
    t[_key - 1] = arguments[_key];
  }
  return e.replace(/\$(\d+)/g, function (e, s) {
    var o;
    var i = parseInt(s, 10) - 1;
    return null !== (o = t[i]) && void 0 !== o ? o : '';
  });
}
var l = /*#__PURE__*/function () {
  function l() {
    var e = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'info';
    (0,classCallCheck/* default */.A)(this, l);
    this.level = e;
  }
  (0,createClass/* default */.A)(l, [{
    key: "setLevel",
    value: function setLevel(e) {
      e && (this.level = e);
    }
  }, {
    key: "shouldLog",
    value: function shouldLog(e) {
      return l.levelOrder[e] <= l.levelOrder[this.level];
    }
  }, {
    key: "error",
    value: function error(e) {
      var _console;
      for (var _len2 = arguments.length, t = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {
        t[_key2 - 1] = arguments[_key2];
      }
      this.shouldLog('error') && (_console = console).error.apply(_console, ['[Live2D Widget][ERROR]', e].concat(t));
    }
  }, {
    key: "warn",
    value: function warn(e) {
      var _console2;
      for (var _len3 = arguments.length, t = new Array(_len3 > 1 ? _len3 - 1 : 0), _key3 = 1; _key3 < _len3; _key3++) {
        t[_key3 - 1] = arguments[_key3];
      }
      this.shouldLog('warn') && (_console2 = console).warn.apply(_console2, ['[Live2D Widget][WARN]', e].concat(t));
    }
  }, {
    key: "info",
    value: function info(e) {
      var _console3;
      for (var _len4 = arguments.length, t = new Array(_len4 > 1 ? _len4 - 1 : 0), _key4 = 1; _key4 < _len4; _key4++) {
        t[_key4 - 1] = arguments[_key4];
      }
      this.shouldLog('info') && (_console3 = console).log.apply(_console3, ['[Live2D Widget][INFO]', e].concat(t));
    }
  }, {
    key: "trace",
    value: function trace(e) {
      var _console4;
      for (var _len5 = arguments.length, t = new Array(_len5 > 1 ? _len5 - 1 : 0), _key5 = 1; _key5 < _len5; _key5++) {
        t[_key5 - 1] = arguments[_key5];
      }
      this.shouldLog('trace') && (_console4 = console).log.apply(_console4, ['[Live2D Widget][TRACE]', e].concat(t));
    }
  }]);
  return l;
}();
l.levelOrder = {
  error: 0,
  warn: 1,
  info: 2,
  trace: 3
};
var a = new l();
var c = /*#__PURE__*/function () {
  function c(e) {
    var t = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
    (0,classCallCheck/* default */.A)(this, c);
    var s;
    this.modelList = null;
    var o = e.apiPath,
      i = e.cdnPath;
    var n = e.cubism2Path,
      l = e.cubism5Path;
    var _c = !1;
    if ('string' == typeof i) {
      i.endsWith('/') || (i += '/'), _c = !0;
    } else if ('string' == typeof o) {
      o.endsWith('/') || (o += '/'), i = o, _c = !0, a.warn('apiPath option is deprecated. Please use cdnPath instead.');
    } else if (!t.length) throw 'Invalid initWidget argument!';
    var d = parseInt(localStorage.getItem('modelId'), 10),
      r = parseInt(localStorage.getItem('modelTexturesId'), 10);
    (isNaN(d) || isNaN(r)) && (r = 0), isNaN(d) && (d = null !== (s = e.modelId) && void 0 !== s ? s : 0), this.useCDN = _c, this.cdnPath = i || '', this.cubism2Path = n || '', this.cubism5Path = l || '', this._modelId = d, this._modelTexturesId = r, this.currentModelVersion = 0, this.loading = !1, this.modelJSONCache = {}, this.models = t;
  }
  (0,createClass/* default */.A)(c, [{
    key: "modelId",
    get: function get() {
      return this._modelId;
    },
    set: function set(e) {
      this._modelId = e, localStorage.setItem('modelId', e.toString());
    }
  }, {
    key: "modelTexturesId",
    get: function get() {
      return this._modelTexturesId;
    },
    set: function set(e) {
      this._modelTexturesId = e, localStorage.setItem('modelTexturesId', e.toString());
    }
  }, {
    key: "resetCanvas",
    value: function resetCanvas() {
      document.getElementById('waifu-canvas').innerHTML = '<canvas id="live2d" width="800" height="800"></canvas>';
    }
  }, {
    key: "fetchWithCache",
    value: function () {
      var _fetchWithCache = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee(e) {
        var t, _s;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee$(_context) {
          while (1) switch (_context.prev = _context.next) {
            case 0:
              if (!(e in this.modelJSONCache)) {
                _context.next = 4;
                break;
              }
              t = this.modelJSONCache[e];
              _context.next = 17;
              break;
            case 4:
              _context.prev = 4;
              _context.next = 7;
              return fetch(e);
            case 7:
              _s = _context.sent;
              _context.next = 10;
              return _s.json();
            case 10:
              t = _context.sent;
              _context.next = 16;
              break;
            case 13:
              _context.prev = 13;
              _context.t0 = _context["catch"](4);
              t = null;
            case 16:
              this.modelJSONCache[e] = t;
            case 17:
              return _context.abrupt("return", t);
            case 18:
            case "end":
              return _context.stop();
          }
        }, _callee, this, [[4, 13]]);
      }));
      function fetchWithCache(_x) {
        return _fetchWithCache.apply(this, arguments);
      }
      return fetchWithCache;
    }()
  }, {
    key: "checkModelVersion",
    value: function checkModelVersion(e) {
      return 3 === e.Version || e.FileReferences ? 3 : 2;
    }
  }, {
    key: "loadLive2D",
    value: function () {
      var _loadLive2D = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee2(e, t) {
        var _o, _yield$import, _e, _yield$import2, _t;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee2$(_context2) {
          while (1) switch (_context2.prev = _context2.next) {
            case 0:
              if (!this.loading) {
                _context2.next = 4;
                break;
              }
              a.warn('Still loading. Abort.');
              _context2.next = 44;
              break;
            case 4:
              this.loading = !0;
              _context2.prev = 5;
              _o = this.checkModelVersion(t);
              if (!(2 === _o)) {
                _context2.next = 28;
                break;
              }
              if (this.cubism2model) {
                _context2.next = 18;
                break;
              }
              if (this.cubism2Path) {
                _context2.next = 11;
                break;
              }
              return _context2.abrupt("return", void a.error('No cubism2Path set, cannot load Cubism 2 Core.'));
            case 11:
              _context2.next = 13;
              return s(this.cubism2Path);
            case 13:
              _context2.next = 15;
              return Promise.resolve(/* import() */).then(__webpack_require__.bind(__webpack_require__, 6218));
            case 15:
              _yield$import = _context2.sent;
              _e = _yield$import.default;
              this.cubism2model = new _e();
            case 18:
              3 === this.currentModelVersion && (this.cubism5model.release(), this.resetCanvas());
              if (!(3 !== this.currentModelVersion && this.cubism2model.gl)) {
                _context2.next = 24;
                break;
              }
              _context2.next = 22;
              return this.cubism2model.changeModelWithJSON(e, t);
            case 22:
              _context2.next = 26;
              break;
            case 24:
              _context2.next = 26;
              return this.cubism2model.init('live2d', e, t);
            case 26:
              _context2.next = 37;
              break;
            case 28:
              if (this.cubism5Path) {
                _context2.next = 30;
                break;
              }
              return _context2.abrupt("return", void a.error('No cubism5Path set, cannot load Cubism 5 Core.'));
            case 30:
              _context2.next = 32;
              return s(this.cubism5Path);
            case 32:
              _context2.next = 34;
              return Promise.resolve(/* import() */).then(__webpack_require__.bind(__webpack_require__, 3999));
            case 34:
              _yield$import2 = _context2.sent;
              _t = _yield$import2.AppDelegate;
              this.cubism5model = new _t(), 2 === this.currentModelVersion && (this.cubism2model.destroy(), this.resetCanvas()), 2 !== this.currentModelVersion && this.cubism5model.subdelegates.at(0) ? this.cubism5model.changeModel(e) : (this.cubism5model.initialize(), this.cubism5model.changeModel(e), this.cubism5model.run());
            case 37:
              a.info("Model ".concat(e, " (Cubism version ").concat(_o, ") loaded")), this.currentModelVersion = _o;
              _context2.next = 43;
              break;
            case 40:
              _context2.prev = 40;
              _context2.t0 = _context2["catch"](5);
              console.error('loadLive2D failed', _context2.t0);
            case 43:
              this.loading = !1;
            case 44:
            case "end":
              return _context2.stop();
          }
        }, _callee2, this, [[5, 40]]);
      }));
      function loadLive2D(_x2, _x3) {
        return _loadLive2D.apply(this, arguments);
      }
      return loadLive2D;
    }()
  }, {
    key: "loadTextureCache",
    value: function () {
      var _loadTextureCache = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee3(e) {
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee3$(_context3) {
          while (1) switch (_context3.prev = _context3.next) {
            case 0:
              _context3.next = 2;
              return this.fetchWithCache("".concat(this.cdnPath, "model/").concat(e, "/textures.cache"));
            case 2:
              _context3.t0 = _context3.sent;
              if (_context3.t0) {
                _context3.next = 5;
                break;
              }
              _context3.t0 = [];
            case 5:
              return _context3.abrupt("return", _context3.t0);
            case 6:
            case "end":
              return _context3.stop();
          }
        }, _callee3, this);
      }));
      function loadTextureCache(_x4) {
        return _loadTextureCache.apply(this, arguments);
      }
      return loadTextureCache;
    }()
  }, {
    key: "loadModel",
    value: function () {
      var _loadModel = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee4(e) {
        var t, s, _e2, _t2, _e3;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee4$(_context4) {
          while (1) switch (_context4.prev = _context4.next) {
            case 0:
              if (!this.useCDN) {
                _context4.next = 14;
                break;
              }
              _e2 = this.modelList.models[this.modelId];
              Array.isArray(_e2) && (_e2 = _e2[this.modelTexturesId]);
              t = "".concat(this.cdnPath, "model/").concat(_e2, "/index.json");
              _context4.next = 6;
              return this.fetchWithCache(t);
            case 6:
              s = _context4.sent;
              if (!(2 === this.checkModelVersion(s))) {
                _context4.next = 12;
                break;
              }
              _context4.next = 10;
              return this.loadTextureCache(_e2);
            case 10:
              _t2 = _context4.sent;
              if (_t2.length > 0) {
                _e3 = _t2[this.modelTexturesId];
                'string' == typeof _e3 && (_e3 = [_e3]), s.textures = _e3;
              }
            case 12:
              _context4.next = 18;
              break;
            case 14:
              t = this.models[this.modelId].paths[this.modelTexturesId];
              _context4.next = 17;
              return this.fetchWithCache(t);
            case 17:
              s = _context4.sent;
            case 18:
              _context4.next = 20;
              return this.loadLive2D(t, s);
            case 20:
              i(e, 4e3, 10);
            case 21:
            case "end":
              return _context4.stop();
          }
        }, _callee4, this);
      }));
      function loadModel(_x5) {
        return _loadModel.apply(this, arguments);
      }
      return loadModel;
    }()
  }, {
    key: "loadRandTexture",
    value: function () {
      var _loadRandTexture = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee5() {
        var e,
          s,
          o,
          n,
          _e4,
          _s2,
          _o2,
          _s3,
          _args5 = arguments;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee5$(_context5) {
          while (1) switch (_context5.prev = _context5.next) {
            case 0:
              e = _args5.length > 0 && _args5[0] !== undefined ? _args5[0] : '';
              s = _args5.length > 1 && _args5[1] !== undefined ? _args5[1] : '';
              o = this.modelId;
              n = !1;
              if (!this.useCDN) {
                _context5.next = 24;
                break;
              }
              _e4 = this.modelList.models[o];
              if (!Array.isArray(_e4)) {
                _context5.next = 10;
                break;
              }
              this.modelTexturesId = t(_e4.length, this.modelTexturesId);
              _context5.next = 22;
              break;
            case 10:
              _s2 = "".concat(this.cdnPath, "model/").concat(_e4, "/index.json");
              _context5.next = 13;
              return this.fetchWithCache(_s2);
            case 13:
              _o2 = _context5.sent;
              if (!(2 === this.checkModelVersion(_o2))) {
                _context5.next = 21;
                break;
              }
              _context5.next = 17;
              return this.loadTextureCache(_e4);
            case 17:
              _s3 = _context5.sent;
              _s3.length <= 1 ? n = !0 : this.modelTexturesId = t(_s3.length, this.modelTexturesId);
              _context5.next = 22;
              break;
            case 21:
              n = !0;
            case 22:
              _context5.next = 25;
              break;
            case 24:
              1 === this.models[o].paths.length ? n = !0 : this.modelTexturesId = t(this.models[o].paths.length, this.modelTexturesId);
            case 25:
              if (!n) {
                _context5.next = 29;
                break;
              }
              i(s, 4e3, 10);
              _context5.next = 31;
              break;
            case 29:
              _context5.next = 31;
              return this.loadModel(e);
            case 31:
            case "end":
              return _context5.stop();
          }
        }, _callee5, this);
      }));
      function loadRandTexture() {
        return _loadRandTexture.apply(this, arguments);
      }
      return loadRandTexture;
    }()
  }, {
    key: "loadNextModel",
    value: function () {
      var _loadNextModel = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee6() {
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee6$(_context6) {
          while (1) switch (_context6.prev = _context6.next) {
            case 0:
              this.modelTexturesId = 0;
              if (!this.useCDN) {
                _context6.next = 7;
                break;
              }
              this.modelId = (this.modelId + 1) % this.modelList.models.length;
              _context6.next = 5;
              return this.loadModel(this.modelList.messages[this.modelId]);
            case 5:
              _context6.next = 10;
              break;
            case 7:
              this.modelId = (this.modelId + 1) % this.models.length;
              _context6.next = 10;
              return this.loadModel(this.models[this.modelId].message);
            case 10:
            case "end":
              return _context6.stop();
          }
        }, _callee6, this);
      }));
      function loadNextModel() {
        return _loadNextModel.apply(this, arguments);
      }
      return loadNextModel;
    }()
  }], [{
    key: "initCheck",
    value: function () {
      var _initCheck = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee7(e) {
        var t,
          s,
          _e5,
          _t3,
          _e6,
          _o3,
          _e7,
          _args7 = arguments;
        return (0,regeneratorRuntime/* default */.A)().wrap(function _callee7$(_context7) {
          while (1) switch (_context7.prev = _context7.next) {
            case 0:
              t = _args7.length > 1 && _args7[1] !== undefined ? _args7[1] : [];
              s = new c(e, t);
              if (!s.useCDN) {
                _context7.next = 26;
                break;
              }
              _context7.next = 5;
              return fetch("".concat(s.cdnPath, "model_list.json"));
            case 5:
              _e5 = _context7.sent;
              _context7.next = 8;
              return _e5.json();
            case 8:
              s.modelList = _context7.sent;
              s.modelId >= s.modelList.models.length && (s.modelId = 0);
              _t3 = s.modelList.models[s.modelId];
              if (!Array.isArray(_t3)) {
                _context7.next = 15;
                break;
              }
              s.modelTexturesId >= _t3.length && (s.modelTexturesId = 0);
              _context7.next = 24;
              break;
            case 15:
              _e6 = "".concat(s.cdnPath, "model/").concat(_t3, "/index.json");
              _context7.next = 18;
              return s.fetchWithCache(_e6);
            case 18:
              _o3 = _context7.sent;
              if (!(2 === s.checkModelVersion(_o3))) {
                _context7.next = 24;
                break;
              }
              _context7.next = 22;
              return s.loadTextureCache(_t3);
            case 22:
              _e7 = _context7.sent;
              s.modelTexturesId >= _e7.length && (s.modelTexturesId = 0);
            case 24:
              _context7.next = 27;
              break;
            case 26:
              s.modelId >= s.models.length && (s.modelId = 0), s.modelTexturesId >= s.models[s.modelId].paths.length && (s.modelTexturesId = 0);
            case 27:
              return _context7.abrupt("return", s);
            case 28:
            case "end":
              return _context7.stop();
          }
        }, _callee7);
      }));
      function initCheck(_x6) {
        return _initCheck.apply(this, arguments);
      }
      return initCheck;
    }()
  }]);
  return c;
}();
var d = /*#__PURE__*/function () {
  function d(e, t, s) {
    (0,classCallCheck/* default */.A)(this, d);
    this.config = t, this.tools = {
      hitokoto: {
        icon: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\x3c!--! Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2024 Fonticons, Inc. --\x3e<path d="M512 240c0 114.9-114.6 208-256 208c-37.1 0-72.3-6.4-104.1-17.9c-11.9 8.7-31.3 20.6-54.3 30.6C73.6 471.1 44.7 480 16 480c-6.5 0-12.3-3.9-14.8-9.9c-2.5-6-1.1-12.8 3.4-17.4c0 0 0 0 0 0s0 0 0 0s0 0 0 0c0 0 0 0 0 0l.3-.3c.3-.3 .7-.7 1.3-1.4c1.1-1.2 2.8-3.1 4.9-5.7c4.1-5 9.6-12.4 15.2-21.6c10-16.6 19.5-38.4 21.4-62.9C17.7 326.8 0 285.1 0 240C0 125.1 114.6 32 256 32s256 93.1 256 208z"/></svg>',
        callback: function () {
          var _callback = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee8() {
            var e, t, o;
            return (0,regeneratorRuntime/* default */.A)().wrap(function _callee8$(_context8) {
              while (1) switch (_context8.prev = _context8.next) {
                case 0:
                  _context8.next = 2;
                  return fetch('https://v1.hitokoto.cn');
                case 2:
                  e = _context8.sent;
                  _context8.next = 5;
                  return e.json();
                case 5:
                  t = _context8.sent;
                  o = n(s.message.hitokoto, t.from, t.creator);
                  i(t.hitokoto, 6e3, 9), setTimeout(function () {
                    i(o, 4e3, 9);
                  }, 6e3);
                case 8:
                case "end":
                  return _context8.stop();
              }
            }, _callee8);
          }));
          function callback() {
            return _callback.apply(this, arguments);
          }
          return callback;
        }()
      },
      asteroids: {
        icon: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\x3c!--! Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2024 Fonticons, Inc. --\x3e<path d="M498.1 5.6c10.1 7 15.4 19.1 13.5 31.2l-64 416c-1.5 9.7-7.4 18.2-16 23s-18.9 5.4-28 1.6L284 427.7l-68.5 74.1c-8.9 9.7-22.9 12.9-35.2 8.1S160 493.2 160 480l0-83.6c0-4 1.5-7.8 4.2-10.8L331.8 202.8c5.8-6.3 5.6-16-.4-22s-15.7-6.4-22-.7L106 360.8 17.7 316.6C7.1 311.3 .3 300.7 0 288.9s5.9-22.8 16.1-28.7l448-256c10.7-6.1 23.9-5.5 34 1.4z"/></svg>',
        callback: function callback() {
          if (window.Asteroids) {
            window.ASTEROIDSPLAYERS || (window.ASTEROIDSPLAYERS = []), window.ASTEROIDSPLAYERS.push(new window.Asteroids());
          } else {
            var _e8 = document.createElement('script');
            _e8.src = 'https://fastly.jsdelivr.net/gh/stevenjoezhang/asteroids/asteroids.js', document.head.appendChild(_e8);
          }
        }
      },
      'switch-model': {
        icon: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\x3c!--! Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2024 Fonticons, Inc. --\x3e<path d="M320 64A64 64 0 1 0 192 64a64 64 0 1 0 128 0zm-96 96c-35.3 0-64 28.7-64 64l0 48c0 17.7 14.3 32 32 32l1.8 0 11.1 99.5c1.8 16.2 15.5 28.5 31.8 28.5l38.7 0c16.3 0 30-12.3 31.8-28.5L318.2 304l1.8 0c17.7 0 32-14.3 32-32l0-48c0-35.3-28.7-64-64-64l-64 0zM132.3 394.2c13-2.4 21.7-14.9 19.3-27.9s-14.9-21.7-27.9-19.3c-32.4 5.9-60.9 14.2-82 24.8c-10.5 5.3-20.3 11.7-27.8 19.6C6.4 399.5 0 410.5 0 424c0 21.4 15.5 36.1 29.1 45c14.7 9.6 34.3 17.3 56.4 23.4C130.2 504.7 190.4 512 256 512s125.8-7.3 170.4-19.6c22.1-6.1 41.8-13.8 56.4-23.4c13.7-8.9 29.1-23.6 29.1-45c0-13.5-6.4-24.5-14-32.6c-7.5-7.9-17.3-14.3-27.8-19.6c-21-10.6-49.5-18.9-82-24.8c-13-2.4-25.5 6.3-27.9 19.3s6.3 25.5 19.3 27.9c30.2 5.5 53.7 12.8 69 20.5c3.2 1.6 5.8 3.1 7.9 4.5c3.6 2.4 3.6 7.2 0 9.6c-8.8 5.7-23.1 11.8-43 17.3C374.3 457 318.5 464 256 464s-118.3-7-157.7-17.9c-19.9-5.5-34.2-11.6-43-17.3c-3.6-2.4-3.6-7.2 0-9.6c2.1-1.4 4.8-2.9 7.9-4.5c15.3-7.7 38.8-14.9 69-20.5z"/></svg>',
        callback: function callback() {
          return e.loadNextModel();
        }
      },
      'switch-texture': {
        icon: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 512">\x3c!--! Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2024 Fonticons, Inc. --\x3e<path d="M211.8 0c7.8 0 14.3 5.7 16.7 13.2C240.8 51.9 277.1 80 320 80s79.2-28.1 91.5-66.8C413.9 5.7 420.4 0 428.2 0l12.6 0c22.5 0 44.2 7.9 61.5 22.3L628.5 127.4c6.6 5.5 10.7 13.5 11.4 22.1s-2.1 17.1-7.8 23.6l-56 64c-11.4 13.1-31.2 14.6-44.6 3.5L480 197.7 480 448c0 35.3-28.7 64-64 64l-192 0c-35.3 0-64-28.7-64-64l0-250.3-51.5 42.9c-13.3 11.1-33.1 9.6-44.6-3.5l-56-64c-5.7-6.5-8.5-15-7.8-23.6s4.8-16.6 11.4-22.1L137.7 22.3C155 7.9 176.7 0 199.2 0l12.6 0z"/></svg>',
        callback: function callback() {
          var t = '',
            o = '';
          s && (t = s.message.changeSuccess, o = s.message.changeFail), e.loadRandTexture(t, o);
        }
      },
      photo: {
        icon: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\x3c!--! Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2024 Fonticons, Inc. --\x3e<path d="M220.6 121.2L271.1 96 448 96l0 96-114.8 0c-21.9-15.1-48.5-24-77.2-24s-55.2 8.9-77.2 24L64 192l0-64 128 0c9.9 0 19.7-2.3 28.6-6.8zM0 128L0 416c0 35.3 28.7 64 64 64l384 0c35.3 0 64-28.7 64-64l0-320c0-35.3-28.7-64-64-64L271.1 32c-9.9 0-19.7 2.3-28.6 6.8L192 64l-32 0 0-16c0-8.8-7.2-16-16-16L80 32c-8.8 0-16 7.2-16 16l0 16C28.7 64 0 92.7 0 128zM168 304a88 88 0 1 1 176 0 88 88 0 1 1 -176 0z"/></svg>',
        callback: function callback() {
          i(s.message.photo, 6e3, 9);
          var e = document.getElementById('live2d');
          if (!e) return;
          var t = e.toDataURL(),
            o = document.createElement('a');
          o.style.display = 'none', o.href = t, o.download = 'live2d-photo.png', document.body.appendChild(o), o.click(), document.body.removeChild(o);
        }
      },
      info: {
        icon: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512">\x3c!--! Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2024 Fonticons, Inc. --\x3e<path d="M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM216 336l24 0 0-64-24 0c-13.3 0-24-10.7-24-24s10.7-24 24-24l48 0c13.3 0 24 10.7 24 24l0 88 8 0c13.3 0 24 10.7 24 24s-10.7 24-24 24l-80 0c-13.3 0-24-10.7-24-24s10.7-24 24-24zm40-208a32 32 0 1 1 0 64 32 32 0 1 1 0-64z"/></svg>',
        callback: function callback() {
          open('https://github.com/stevenjoezhang/live2d-widget');
        }
      },
      quit: {
        icon: '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 384 512">\x3c!--! Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2024 Fonticons, Inc. --\x3e<path d="M342.6 150.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L192 210.7 86.6 105.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3L146.7 256 41.4 361.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 301.3 297.4 406.6c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L237.3 256 342.6 150.6z"/></svg>',
        callback: function callback() {
          localStorage.setItem('waifu-display', Date.now().toString());
          i(s.message.goodbye, 2e3, 11);
          var e = document.getElementById('waifu');
          e && (e.classList.remove('waifu-active'), setTimeout(function () {
            e.classList.add('waifu-hidden');
            var t = document.getElementById('waifu-toggle');
            null == t || t.classList.add('waifu-toggle-active');
          }, 3e3));
        }
      }
    };
  }
  (0,createClass/* default */.A)(d, [{
    key: "registerTools",
    value: function registerTools() {
      var e;
      Array.isArray(this.config.tools) || (this.config.tools = Object.keys(this.tools));
      var _iterator = _createForOfIteratorHelper(this.config.tools),
        _step;
      try {
        for (_iterator.s(); !(_step = _iterator.n()).done;) {
          var _t4 = _step.value;
          if (this.tools[_t4]) {
            var _this$tools$_t = this.tools[_t4],
              s = _this$tools$_t.icon,
              _o4 = _this$tools$_t.callback,
              _i = document.createElement('span');
            _i.id = "waifu-tool-".concat(_t4), _i.innerHTML = s, null === (e = document.getElementById('waifu-tool')) || void 0 === e || e.insertAdjacentElement('beforeend', _i), _i.addEventListener('click', _o4);
          }
        }
      } catch (err) {
        _iterator.e(err);
      } finally {
        _iterator.f();
      }
    }
  }]);
  return d;
}();
function r(_x7) {
  return _r.apply(this, arguments);
}
function _r() {
  _r = (0,asyncToGenerator/* default */.A)( /*#__PURE__*/(0,regeneratorRuntime/* default */.A)().mark(function _callee9(t) {
    var s, o, l, _s4, a;
    return (0,regeneratorRuntime/* default */.A)().wrap(function _callee9$(_context9) {
      while (1) switch (_context9.prev = _context9.next) {
        case 0:
          localStorage.removeItem('waifu-display'), sessionStorage.removeItem('waifu-message-priority'), document.body.insertAdjacentHTML('beforeend', '<div id="waifu">\n       <div id="waifu-tips"></div>\n       <div id="waifu-canvas">\n         <canvas id="live2d" width="800" height="800"></canvas>\n       </div>\n       <div id="waifu-tool"></div>\n     </div>');
          l = [];
          if (!t.waifuPath) {
            _context9.next = 12;
            break;
          }
          _context9.next = 5;
          return fetch(t.waifuPath);
        case 5:
          _s4 = _context9.sent;
          _context9.next = 8;
          return _s4.json();
        case 8:
          o = _context9.sent;
          l = o.models;
          (function (t) {
            var s,
              o = !1;
            var n = t.message.default;
            var l;
            t.seasons.forEach(function (_ref) {
              var t = _ref.date,
                s = _ref.text;
              var o = new Date(),
                i = t.split('-')[0],
                l = t.split('-')[1] || i;
              Number(i.split('/')[0]) <= o.getMonth() + 1 && o.getMonth() + 1 <= Number(l.split('/')[0]) && Number(i.split('/')[1]) <= o.getDate() && o.getDate() <= Number(l.split('/')[1]) && (s = (s = e(s)).replace('{year}', String(o.getFullYear())), n.push(s));
            }), window.addEventListener('mousemove', function () {
              return o = !0;
            }), window.addEventListener('keydown', function () {
              return o = !0;
            }), setInterval(function () {
              o ? (o = !1, clearInterval(s), s = null) : s || (s = setInterval(function () {
                i(n, 6e3, 9);
              }, 2e4));
            }, 1e3), window.addEventListener('mouseover', function (s) {
              var o;
              var _iterator2 = _createForOfIteratorHelper(t.mouseover),
                _step2;
              try {
                for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
                  var _step2$value = _step2.value,
                    _n = _step2$value.selector,
                    _a = _step2$value.text;
                  if (null === (o = s.target) || void 0 === o ? void 0 : o.closest(_n)) {
                    if (l === _n) return;
                    return l = _n, _a = e(_a), _a = _a.replace('{text}', s.target.innerText), void i(_a, 4e3, 8);
                  }
                }
              } catch (err) {
                _iterator2.e(err);
              } finally {
                _iterator2.f();
              }
            }), window.addEventListener('click', function (s) {
              var o;
              var _iterator3 = _createForOfIteratorHelper(t.click),
                _step3;
              try {
                for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {
                  var _step3$value = _step3.value,
                    _n2 = _step3$value.selector,
                    _l = _step3$value.text;
                  if (null === (o = s.target) || void 0 === o ? void 0 : o.closest(_n2)) return _l = e(_l), _l = _l.replace('{text}', s.target.innerText), void i(_l, 4e3, 8);
                }
              } catch (err) {
                _iterator3.e(err);
              } finally {
                _iterator3.f();
              }
            }), window.addEventListener('live2d:hoverbody', function () {
              i(e(t.message.hoverBody), 4e3, 8, !1);
            }), window.addEventListener('live2d:tapbody', function () {
              i(e(t.message.tapBody), 4e3, 9);
            });
            var a = function a() {};
            console.log('%c', a), a.toString = function () {
              i(t.message.console, 6e3, 9);
            }, window.addEventListener('copy', function () {
              i(t.message.copy, 6e3, 9);
            }), window.addEventListener('visibilitychange', function () {
              document.hidden || i(t.message.visibilitychange, 6e3, 9);
            });
          })(o);
          i(function (e, t, s) {
            if ('/' === location.pathname) {
              var _iterator4 = _createForOfIteratorHelper(e),
                _step4;
              try {
                for (_iterator4.s(); !(_step4 = _iterator4.n()).done;) {
                  var _step4$value = _step4.value,
                    _t5 = _step4$value.hour,
                    _s5 = _step4$value.text;
                  var _e9 = new Date(),
                    _o5 = _t5.split('-')[0],
                    _i2 = _t5.split('-')[1] || _o5;
                  if (Number(_o5) <= _e9.getHours() && _e9.getHours() <= Number(_i2)) return _s5;
                }
              } catch (err) {
                _iterator4.e(err);
              } finally {
                _iterator4.f();
              }
            }
            var o = n(t, document.title);
            if ('' !== document.referrer) {
              var _e10 = new URL(document.referrer);
              return location.hostname === _e10.hostname ? o : "".concat(n(s, _e10.hostname), "<br>").concat(o);
            }
            return o;
          }(o.time, o.message.welcome, o.message.referrer), 7e3, 11);
        case 12:
          _context9.next = 14;
          return c.initCheck(t, l);
        case 14:
          a = _context9.sent;
          _context9.next = 17;
          return a.loadModel('');
        case 17:
          new d(a, t, o).registerTools();
          t.drag && function () {
            var e = document.getElementById('waifu');
            if (!e) return;
            var t = window.innerWidth,
              s = window.innerHeight;
            var o = e.offsetWidth,
              i = e.offsetHeight;
            e.addEventListener('mousedown', function (n) {
              if (2 === n.button) return;
              var l = document.getElementById('live2d');
              if (n.target !== l) return;
              n.preventDefault();
              var a = n.offsetX,
                c = n.offsetY;
              document.onmousemove = function (n) {
                var l = n.clientX,
                  d = n.clientY;
                var r = l - a,
                  m = d - c;
                m < 0 ? m = 0 : m >= s - i && (m = s - i), r < 0 ? r = 0 : r >= t - o && (r = t - o), e.style.top = m + 'px', e.style.left = r + 'px';
              }, document.onmouseup = function () {
                document.onmousemove = null;
              };
            }), window.onresize = function () {
              t = window.innerWidth, s = window.innerHeight;
            };
          }();
          null === (s = document.getElementById('waifu')) || void 0 === s || s.classList.add('waifu-active');
        case 20:
        case "end":
          return _context9.stop();
      }
    }, _callee9);
  }));
  return _r.apply(this, arguments);
}
window.initWidget = function (e) {
  if ('string' == typeof e) return void a.error('Your config for Live2D initWidget is outdated. Please refer to https://github.com/stevenjoezhang/live2d-widget/blob/master/dist/autoload.js');
  a.setLevel(e.logLevel), document.body.insertAdjacentHTML('beforeend', '<div id="waifu-toggle">\n       <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 512">\x3c!--! Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2024 Fonticons, Inc. --\x3e<path d="M96 64a64 64 0 1 1 128 0A64 64 0 1 1 96 64zm48 320l0 96c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-192.2L59.1 321c-9.4 15-29.2 19.4-44.1 10S-4.5 301.9 4.9 287l39.9-63.3C69.7 184 113.2 160 160 160s90.3 24 115.2 63.6L315.1 287c9.4 15 4.9 34.7-10 44.1s-34.7 4.9-44.1-10L240 287.8 240 480c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-96-32 0z"/></svg>\n     </div>');
  var t = document.getElementById('waifu-toggle');
  null == t || t.addEventListener('click', function () {
    var s;
    null == t || t.classList.remove('waifu-toggle-active'), (null == t ? void 0 : t.getAttribute('first-time')) ? (r(e), null == t || t.removeAttribute('first-time')) : (localStorage.removeItem('waifu-display'), null === (s = document.getElementById('waifu')) || void 0 === s || s.classList.remove('waifu-hidden'), setTimeout(function () {
      var e;
      null === (e = document.getElementById('waifu')) || void 0 === e || e.classList.add('waifu-active');
    }, 0));
  }), localStorage.getItem('waifu-display') && Date.now() - Number(localStorage.getItem("waifu-display")) <= 864e5 ? (null == t || t.setAttribute("first-time", "true"), setTimeout(function () {
    null == t || t.classList.add("waifu-toggle-active");
  }, 0)) : r(e);
};


/***/ }),

/***/ 9306:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isCallable = __webpack_require__(4901);
var tryToString = __webpack_require__(6823);

var $TypeError = TypeError;

// `Assert: IsCallable(argument) is true`
module.exports = function (argument) {
  if (isCallable(argument)) return argument;
  throw new $TypeError(tryToString(argument) + ' is not a function');
};


/***/ }),

/***/ 5548:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isConstructor = __webpack_require__(3517);
var tryToString = __webpack_require__(6823);

var $TypeError = TypeError;

// `Assert: IsConstructor(argument) is true`
module.exports = function (argument) {
  if (isConstructor(argument)) return argument;
  throw new $TypeError(tryToString(argument) + ' is not a constructor');
};


/***/ }),

/***/ 3506:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isPossiblePrototype = __webpack_require__(3925);

var $String = String;
var $TypeError = TypeError;

module.exports = function (argument) {
  if (isPossiblePrototype(argument)) return argument;
  throw new $TypeError("Can't set " + $String(argument) + ' as a prototype');
};


/***/ }),

/***/ 6469:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var wellKnownSymbol = __webpack_require__(8227);
var create = __webpack_require__(2360);
var defineProperty = (__webpack_require__(4913).f);

var UNSCOPABLES = wellKnownSymbol('unscopables');
var ArrayPrototype = Array.prototype;

// Array.prototype[@@unscopables]
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
if (ArrayPrototype[UNSCOPABLES] === undefined) {
  defineProperty(ArrayPrototype, UNSCOPABLES, {
    configurable: true,
    value: create(null)
  });
}

// add a key to Array.prototype[@@unscopables]
module.exports = function (key) {
  ArrayPrototype[UNSCOPABLES][key] = true;
};


/***/ }),

/***/ 7829:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var charAt = (__webpack_require__(8183).charAt);

// `AdvanceStringIndex` abstract operation
// https://tc39.es/ecma262/#sec-advancestringindex
module.exports = function (S, index, unicode) {
  return index + (unicode ? charAt(S, index).length : 1);
};


/***/ }),

/***/ 679:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isPrototypeOf = __webpack_require__(1625);

var $TypeError = TypeError;

module.exports = function (it, Prototype) {
  if (isPrototypeOf(Prototype, it)) return it;
  throw new $TypeError('Incorrect invocation');
};


/***/ }),

/***/ 8551:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isObject = __webpack_require__(34);

var $String = String;
var $TypeError = TypeError;

// `Assert: Type(argument) is Object`
module.exports = function (argument) {
  if (isObject(argument)) return argument;
  throw new $TypeError($String(argument) + ' is not an object');
};


/***/ }),

/***/ 7811:
/***/ (function(module) {


// eslint-disable-next-line es/no-typed-arrays -- safe
module.exports = typeof ArrayBuffer != 'undefined' && typeof DataView != 'undefined';


/***/ }),

/***/ 7394:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThisAccessor = __webpack_require__(6706);
var classof = __webpack_require__(4576);

var $TypeError = TypeError;

// Includes
// - Perform ? RequireInternalSlot(O, [[ArrayBufferData]]).
// - If IsSharedArrayBuffer(O) is true, throw a TypeError exception.
module.exports = uncurryThisAccessor(ArrayBuffer.prototype, 'byteLength', 'get') || function (O) {
  if (classof(O) !== 'ArrayBuffer') throw new $TypeError('ArrayBuffer expected');
  return O.byteLength;
};


/***/ }),

/***/ 3238:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var arrayBufferByteLength = __webpack_require__(7394);

var slice = uncurryThis(ArrayBuffer.prototype.slice);

module.exports = function (O) {
  if (arrayBufferByteLength(O) !== 0) return false;
  try {
    slice(O, 0, 0);
    return false;
  } catch (error) {
    return true;
  }
};


/***/ }),

/***/ 5652:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


// FF26- bug: ArrayBuffers are non-extensible, but Object.isExtensible does not report it
var fails = __webpack_require__(9039);

module.exports = fails(function () {
  if (typeof ArrayBuffer == 'function') {
    var buffer = new ArrayBuffer(8);
    // eslint-disable-next-line es/no-object-isextensible, es/no-object-defineproperty -- safe
    if (Object.isExtensible(buffer)) Object.defineProperty(buffer, 'a', { value: 8 });
  }
});


/***/ }),

/***/ 5636:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var uncurryThis = __webpack_require__(9504);
var uncurryThisAccessor = __webpack_require__(6706);
var toIndex = __webpack_require__(7696);
var isDetached = __webpack_require__(3238);
var arrayBufferByteLength = __webpack_require__(7394);
var detachTransferable = __webpack_require__(4483);
var PROPER_STRUCTURED_CLONE_TRANSFER = __webpack_require__(1548);

var structuredClone = global.structuredClone;
var ArrayBuffer = global.ArrayBuffer;
var DataView = global.DataView;
var TypeError = global.TypeError;
var min = Math.min;
var ArrayBufferPrototype = ArrayBuffer.prototype;
var DataViewPrototype = DataView.prototype;
var slice = uncurryThis(ArrayBufferPrototype.slice);
var isResizable = uncurryThisAccessor(ArrayBufferPrototype, 'resizable', 'get');
var maxByteLength = uncurryThisAccessor(ArrayBufferPrototype, 'maxByteLength', 'get');
var getInt8 = uncurryThis(DataViewPrototype.getInt8);
var setInt8 = uncurryThis(DataViewPrototype.setInt8);

module.exports = (PROPER_STRUCTURED_CLONE_TRANSFER || detachTransferable) && function (arrayBuffer, newLength, preserveResizability) {
  var byteLength = arrayBufferByteLength(arrayBuffer);
  var newByteLength = newLength === undefined ? byteLength : toIndex(newLength);
  var fixedLength = !isResizable || !isResizable(arrayBuffer);
  var newBuffer;
  if (isDetached(arrayBuffer)) throw new TypeError('ArrayBuffer is detached');
  if (PROPER_STRUCTURED_CLONE_TRANSFER) {
    arrayBuffer = structuredClone(arrayBuffer, { transfer: [arrayBuffer] });
    if (byteLength === newByteLength && (preserveResizability || fixedLength)) return arrayBuffer;
  }
  if (byteLength >= newByteLength && (!preserveResizability || fixedLength)) {
    newBuffer = slice(arrayBuffer, 0, newByteLength);
  } else {
    var options = preserveResizability && !fixedLength && maxByteLength ? { maxByteLength: maxByteLength(arrayBuffer) } : undefined;
    newBuffer = new ArrayBuffer(newByteLength, options);
    var a = new DataView(arrayBuffer);
    var b = new DataView(newBuffer);
    var copyLength = min(newByteLength, byteLength);
    for (var i = 0; i < copyLength; i++) setInt8(b, i, getInt8(a, i));
  }
  if (!PROPER_STRUCTURED_CLONE_TRANSFER) detachTransferable(arrayBuffer);
  return newBuffer;
};


/***/ }),

/***/ 4644:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var NATIVE_ARRAY_BUFFER = __webpack_require__(7811);
var DESCRIPTORS = __webpack_require__(3724);
var global = __webpack_require__(4475);
var isCallable = __webpack_require__(4901);
var isObject = __webpack_require__(34);
var hasOwn = __webpack_require__(9297);
var classof = __webpack_require__(6955);
var tryToString = __webpack_require__(6823);
var createNonEnumerableProperty = __webpack_require__(6699);
var defineBuiltIn = __webpack_require__(6840);
var defineBuiltInAccessor = __webpack_require__(2106);
var isPrototypeOf = __webpack_require__(1625);
var getPrototypeOf = __webpack_require__(2787);
var setPrototypeOf = __webpack_require__(2967);
var wellKnownSymbol = __webpack_require__(8227);
var uid = __webpack_require__(3392);
var InternalStateModule = __webpack_require__(1181);

var enforceInternalState = InternalStateModule.enforce;
var getInternalState = InternalStateModule.get;
var Int8Array = global.Int8Array;
var Int8ArrayPrototype = Int8Array && Int8Array.prototype;
var Uint8ClampedArray = global.Uint8ClampedArray;
var Uint8ClampedArrayPrototype = Uint8ClampedArray && Uint8ClampedArray.prototype;
var TypedArray = Int8Array && getPrototypeOf(Int8Array);
var TypedArrayPrototype = Int8ArrayPrototype && getPrototypeOf(Int8ArrayPrototype);
var ObjectPrototype = Object.prototype;
var TypeError = global.TypeError;

var TO_STRING_TAG = wellKnownSymbol('toStringTag');
var TYPED_ARRAY_TAG = uid('TYPED_ARRAY_TAG');
var TYPED_ARRAY_CONSTRUCTOR = 'TypedArrayConstructor';
// Fixing native typed arrays in Opera Presto crashes the browser, see #595
var NATIVE_ARRAY_BUFFER_VIEWS = NATIVE_ARRAY_BUFFER && !!setPrototypeOf && classof(global.opera) !== 'Opera';
var TYPED_ARRAY_TAG_REQUIRED = false;
var NAME, Constructor, Prototype;

var TypedArrayConstructorsList = {
  Int8Array: 1,
  Uint8Array: 1,
  Uint8ClampedArray: 1,
  Int16Array: 2,
  Uint16Array: 2,
  Int32Array: 4,
  Uint32Array: 4,
  Float32Array: 4,
  Float64Array: 8
};

var BigIntArrayConstructorsList = {
  BigInt64Array: 8,
  BigUint64Array: 8
};

var isView = function isView(it) {
  if (!isObject(it)) return false;
  var klass = classof(it);
  return klass === 'DataView'
    || hasOwn(TypedArrayConstructorsList, klass)
    || hasOwn(BigIntArrayConstructorsList, klass);
};

var getTypedArrayConstructor = function (it) {
  var proto = getPrototypeOf(it);
  if (!isObject(proto)) return;
  var state = getInternalState(proto);
  return (state && hasOwn(state, TYPED_ARRAY_CONSTRUCTOR)) ? state[TYPED_ARRAY_CONSTRUCTOR] : getTypedArrayConstructor(proto);
};

var isTypedArray = function (it) {
  if (!isObject(it)) return false;
  var klass = classof(it);
  return hasOwn(TypedArrayConstructorsList, klass)
    || hasOwn(BigIntArrayConstructorsList, klass);
};

var aTypedArray = function (it) {
  if (isTypedArray(it)) return it;
  throw new TypeError('Target is not a typed array');
};

var aTypedArrayConstructor = function (C) {
  if (isCallable(C) && (!setPrototypeOf || isPrototypeOf(TypedArray, C))) return C;
  throw new TypeError(tryToString(C) + ' is not a typed array constructor');
};

var exportTypedArrayMethod = function (KEY, property, forced, options) {
  if (!DESCRIPTORS) return;
  if (forced) for (var ARRAY in TypedArrayConstructorsList) {
    var TypedArrayConstructor = global[ARRAY];
    if (TypedArrayConstructor && hasOwn(TypedArrayConstructor.prototype, KEY)) try {
      delete TypedArrayConstructor.prototype[KEY];
    } catch (error) {
      // old WebKit bug - some methods are non-configurable
      try {
        TypedArrayConstructor.prototype[KEY] = property;
      } catch (error2) { /* empty */ }
    }
  }
  if (!TypedArrayPrototype[KEY] || forced) {
    defineBuiltIn(TypedArrayPrototype, KEY, forced ? property
      : NATIVE_ARRAY_BUFFER_VIEWS && Int8ArrayPrototype[KEY] || property, options);
  }
};

var exportTypedArrayStaticMethod = function (KEY, property, forced) {
  var ARRAY, TypedArrayConstructor;
  if (!DESCRIPTORS) return;
  if (setPrototypeOf) {
    if (forced) for (ARRAY in TypedArrayConstructorsList) {
      TypedArrayConstructor = global[ARRAY];
      if (TypedArrayConstructor && hasOwn(TypedArrayConstructor, KEY)) try {
        delete TypedArrayConstructor[KEY];
      } catch (error) { /* empty */ }
    }
    if (!TypedArray[KEY] || forced) {
      // V8 ~ Chrome 49-50 `%TypedArray%` methods are non-writable non-configurable
      try {
        return defineBuiltIn(TypedArray, KEY, forced ? property : NATIVE_ARRAY_BUFFER_VIEWS && TypedArray[KEY] || property);
      } catch (error) { /* empty */ }
    } else return;
  }
  for (ARRAY in TypedArrayConstructorsList) {
    TypedArrayConstructor = global[ARRAY];
    if (TypedArrayConstructor && (!TypedArrayConstructor[KEY] || forced)) {
      defineBuiltIn(TypedArrayConstructor, KEY, property);
    }
  }
};

for (NAME in TypedArrayConstructorsList) {
  Constructor = global[NAME];
  Prototype = Constructor && Constructor.prototype;
  if (Prototype) enforceInternalState(Prototype)[TYPED_ARRAY_CONSTRUCTOR] = Constructor;
  else NATIVE_ARRAY_BUFFER_VIEWS = false;
}

for (NAME in BigIntArrayConstructorsList) {
  Constructor = global[NAME];
  Prototype = Constructor && Constructor.prototype;
  if (Prototype) enforceInternalState(Prototype)[TYPED_ARRAY_CONSTRUCTOR] = Constructor;
}

// WebKit bug - typed arrays constructors prototype is Object.prototype
if (!NATIVE_ARRAY_BUFFER_VIEWS || !isCallable(TypedArray) || TypedArray === Function.prototype) {
  // eslint-disable-next-line no-shadow -- safe
  TypedArray = function TypedArray() {
    throw new TypeError('Incorrect invocation');
  };
  if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) {
    if (global[NAME]) setPrototypeOf(global[NAME], TypedArray);
  }
}

if (!NATIVE_ARRAY_BUFFER_VIEWS || !TypedArrayPrototype || TypedArrayPrototype === ObjectPrototype) {
  TypedArrayPrototype = TypedArray.prototype;
  if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) {
    if (global[NAME]) setPrototypeOf(global[NAME].prototype, TypedArrayPrototype);
  }
}

// WebKit bug - one more object in Uint8ClampedArray prototype chain
if (NATIVE_ARRAY_BUFFER_VIEWS && getPrototypeOf(Uint8ClampedArrayPrototype) !== TypedArrayPrototype) {
  setPrototypeOf(Uint8ClampedArrayPrototype, TypedArrayPrototype);
}

if (DESCRIPTORS && !hasOwn(TypedArrayPrototype, TO_STRING_TAG)) {
  TYPED_ARRAY_TAG_REQUIRED = true;
  defineBuiltInAccessor(TypedArrayPrototype, TO_STRING_TAG, {
    configurable: true,
    get: function () {
      return isObject(this) ? this[TYPED_ARRAY_TAG] : undefined;
    }
  });
  for (NAME in TypedArrayConstructorsList) if (global[NAME]) {
    createNonEnumerableProperty(global[NAME], TYPED_ARRAY_TAG, NAME);
  }
}

module.exports = {
  NATIVE_ARRAY_BUFFER_VIEWS: NATIVE_ARRAY_BUFFER_VIEWS,
  TYPED_ARRAY_TAG: TYPED_ARRAY_TAG_REQUIRED && TYPED_ARRAY_TAG,
  aTypedArray: aTypedArray,
  aTypedArrayConstructor: aTypedArrayConstructor,
  exportTypedArrayMethod: exportTypedArrayMethod,
  exportTypedArrayStaticMethod: exportTypedArrayStaticMethod,
  getTypedArrayConstructor: getTypedArrayConstructor,
  isView: isView,
  isTypedArray: isTypedArray,
  TypedArray: TypedArray,
  TypedArrayPrototype: TypedArrayPrototype
};


/***/ }),

/***/ 6346:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var uncurryThis = __webpack_require__(9504);
var DESCRIPTORS = __webpack_require__(3724);
var NATIVE_ARRAY_BUFFER = __webpack_require__(7811);
var FunctionName = __webpack_require__(350);
var createNonEnumerableProperty = __webpack_require__(6699);
var defineBuiltInAccessor = __webpack_require__(2106);
var defineBuiltIns = __webpack_require__(6279);
var fails = __webpack_require__(9039);
var anInstance = __webpack_require__(679);
var toIntegerOrInfinity = __webpack_require__(1291);
var toLength = __webpack_require__(8014);
var toIndex = __webpack_require__(7696);
var fround = __webpack_require__(5617);
var IEEE754 = __webpack_require__(8490);
var getPrototypeOf = __webpack_require__(2787);
var setPrototypeOf = __webpack_require__(2967);
var arrayFill = __webpack_require__(4373);
var arraySlice = __webpack_require__(7680);
var inheritIfRequired = __webpack_require__(3167);
var copyConstructorProperties = __webpack_require__(7740);
var setToStringTag = __webpack_require__(687);
var InternalStateModule = __webpack_require__(1181);

var PROPER_FUNCTION_NAME = FunctionName.PROPER;
var CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;
var ARRAY_BUFFER = 'ArrayBuffer';
var DATA_VIEW = 'DataView';
var PROTOTYPE = 'prototype';
var WRONG_LENGTH = 'Wrong length';
var WRONG_INDEX = 'Wrong index';
var getInternalArrayBufferState = InternalStateModule.getterFor(ARRAY_BUFFER);
var getInternalDataViewState = InternalStateModule.getterFor(DATA_VIEW);
var setInternalState = InternalStateModule.set;
var NativeArrayBuffer = global[ARRAY_BUFFER];
var $ArrayBuffer = NativeArrayBuffer;
var ArrayBufferPrototype = $ArrayBuffer && $ArrayBuffer[PROTOTYPE];
var $DataView = global[DATA_VIEW];
var DataViewPrototype = $DataView && $DataView[PROTOTYPE];
var ObjectPrototype = Object.prototype;
var Array = global.Array;
var RangeError = global.RangeError;
var fill = uncurryThis(arrayFill);
var reverse = uncurryThis([].reverse);

var packIEEE754 = IEEE754.pack;
var unpackIEEE754 = IEEE754.unpack;

var packInt8 = function (number) {
  return [number & 0xFF];
};

var packInt16 = function (number) {
  return [number & 0xFF, number >> 8 & 0xFF];
};

var packInt32 = function (number) {
  return [number & 0xFF, number >> 8 & 0xFF, number >> 16 & 0xFF, number >> 24 & 0xFF];
};

var unpackInt32 = function (buffer) {
  return buffer[3] << 24 | buffer[2] << 16 | buffer[1] << 8 | buffer[0];
};

var packFloat32 = function (number) {
  return packIEEE754(fround(number), 23, 4);
};

var packFloat64 = function (number) {
  return packIEEE754(number, 52, 8);
};

var addGetter = function (Constructor, key, getInternalState) {
  defineBuiltInAccessor(Constructor[PROTOTYPE], key, {
    configurable: true,
    get: function () {
      return getInternalState(this)[key];
    }
  });
};

var get = function (view, count, index, isLittleEndian) {
  var store = getInternalDataViewState(view);
  var intIndex = toIndex(index);
  var boolIsLittleEndian = !!isLittleEndian;
  if (intIndex + count > store.byteLength) throw new RangeError(WRONG_INDEX);
  var bytes = store.bytes;
  var start = intIndex + store.byteOffset;
  var pack = arraySlice(bytes, start, start + count);
  return boolIsLittleEndian ? pack : reverse(pack);
};

var set = function (view, count, index, conversion, value, isLittleEndian) {
  var store = getInternalDataViewState(view);
  var intIndex = toIndex(index);
  var pack = conversion(+value);
  var boolIsLittleEndian = !!isLittleEndian;
  if (intIndex + count > store.byteLength) throw new RangeError(WRONG_INDEX);
  var bytes = store.bytes;
  var start = intIndex + store.byteOffset;
  for (var i = 0; i < count; i++) bytes[start + i] = pack[boolIsLittleEndian ? i : count - i - 1];
};

if (!NATIVE_ARRAY_BUFFER) {
  $ArrayBuffer = function ArrayBuffer(length) {
    anInstance(this, ArrayBufferPrototype);
    var byteLength = toIndex(length);
    setInternalState(this, {
      type: ARRAY_BUFFER,
      bytes: fill(Array(byteLength), 0),
      byteLength: byteLength
    });
    if (!DESCRIPTORS) {
      this.byteLength = byteLength;
      this.detached = false;
    }
  };

  ArrayBufferPrototype = $ArrayBuffer[PROTOTYPE];

  $DataView = function DataView(buffer, byteOffset, byteLength) {
    anInstance(this, DataViewPrototype);
    anInstance(buffer, ArrayBufferPrototype);
    var bufferState = getInternalArrayBufferState(buffer);
    var bufferLength = bufferState.byteLength;
    var offset = toIntegerOrInfinity(byteOffset);
    if (offset < 0 || offset > bufferLength) throw new RangeError('Wrong offset');
    byteLength = byteLength === undefined ? bufferLength - offset : toLength(byteLength);
    if (offset + byteLength > bufferLength) throw new RangeError(WRONG_LENGTH);
    setInternalState(this, {
      type: DATA_VIEW,
      buffer: buffer,
      byteLength: byteLength,
      byteOffset: offset,
      bytes: bufferState.bytes
    });
    if (!DESCRIPTORS) {
      this.buffer = buffer;
      this.byteLength = byteLength;
      this.byteOffset = offset;
    }
  };

  DataViewPrototype = $DataView[PROTOTYPE];

  if (DESCRIPTORS) {
    addGetter($ArrayBuffer, 'byteLength', getInternalArrayBufferState);
    addGetter($DataView, 'buffer', getInternalDataViewState);
    addGetter($DataView, 'byteLength', getInternalDataViewState);
    addGetter($DataView, 'byteOffset', getInternalDataViewState);
  }

  defineBuiltIns(DataViewPrototype, {
    getInt8: function getInt8(byteOffset) {
      return get(this, 1, byteOffset)[0] << 24 >> 24;
    },
    getUint8: function getUint8(byteOffset) {
      return get(this, 1, byteOffset)[0];
    },
    getInt16: function getInt16(byteOffset /* , littleEndian */) {
      var bytes = get(this, 2, byteOffset, arguments.length > 1 ? arguments[1] : false);
      return (bytes[1] << 8 | bytes[0]) << 16 >> 16;
    },
    getUint16: function getUint16(byteOffset /* , littleEndian */) {
      var bytes = get(this, 2, byteOffset, arguments.length > 1 ? arguments[1] : false);
      return bytes[1] << 8 | bytes[0];
    },
    getInt32: function getInt32(byteOffset /* , littleEndian */) {
      return unpackInt32(get(this, 4, byteOffset, arguments.length > 1 ? arguments[1] : false));
    },
    getUint32: function getUint32(byteOffset /* , littleEndian */) {
      return unpackInt32(get(this, 4, byteOffset, arguments.length > 1 ? arguments[1] : false)) >>> 0;
    },
    getFloat32: function getFloat32(byteOffset /* , littleEndian */) {
      return unpackIEEE754(get(this, 4, byteOffset, arguments.length > 1 ? arguments[1] : false), 23);
    },
    getFloat64: function getFloat64(byteOffset /* , littleEndian */) {
      return unpackIEEE754(get(this, 8, byteOffset, arguments.length > 1 ? arguments[1] : false), 52);
    },
    setInt8: function setInt8(byteOffset, value) {
      set(this, 1, byteOffset, packInt8, value);
    },
    setUint8: function setUint8(byteOffset, value) {
      set(this, 1, byteOffset, packInt8, value);
    },
    setInt16: function setInt16(byteOffset, value /* , littleEndian */) {
      set(this, 2, byteOffset, packInt16, value, arguments.length > 2 ? arguments[2] : false);
    },
    setUint16: function setUint16(byteOffset, value /* , littleEndian */) {
      set(this, 2, byteOffset, packInt16, value, arguments.length > 2 ? arguments[2] : false);
    },
    setInt32: function setInt32(byteOffset, value /* , littleEndian */) {
      set(this, 4, byteOffset, packInt32, value, arguments.length > 2 ? arguments[2] : false);
    },
    setUint32: function setUint32(byteOffset, value /* , littleEndian */) {
      set(this, 4, byteOffset, packInt32, value, arguments.length > 2 ? arguments[2] : false);
    },
    setFloat32: function setFloat32(byteOffset, value /* , littleEndian */) {
      set(this, 4, byteOffset, packFloat32, value, arguments.length > 2 ? arguments[2] : false);
    },
    setFloat64: function setFloat64(byteOffset, value /* , littleEndian */) {
      set(this, 8, byteOffset, packFloat64, value, arguments.length > 2 ? arguments[2] : false);
    }
  });
} else {
  var INCORRECT_ARRAY_BUFFER_NAME = PROPER_FUNCTION_NAME && NativeArrayBuffer.name !== ARRAY_BUFFER;
  /* eslint-disable no-new -- required for testing */
  if (!fails(function () {
    NativeArrayBuffer(1);
  }) || !fails(function () {
    new NativeArrayBuffer(-1);
  }) || fails(function () {
    new NativeArrayBuffer();
    new NativeArrayBuffer(1.5);
    new NativeArrayBuffer(NaN);
    return NativeArrayBuffer.length !== 1 || INCORRECT_ARRAY_BUFFER_NAME && !CONFIGURABLE_FUNCTION_NAME;
  })) {
    /* eslint-enable no-new -- required for testing */
    $ArrayBuffer = function ArrayBuffer(length) {
      anInstance(this, ArrayBufferPrototype);
      return inheritIfRequired(new NativeArrayBuffer(toIndex(length)), this, $ArrayBuffer);
    };

    $ArrayBuffer[PROTOTYPE] = ArrayBufferPrototype;

    ArrayBufferPrototype.constructor = $ArrayBuffer;

    copyConstructorProperties($ArrayBuffer, NativeArrayBuffer);
  } else if (INCORRECT_ARRAY_BUFFER_NAME && CONFIGURABLE_FUNCTION_NAME) {
    createNonEnumerableProperty(NativeArrayBuffer, 'name', ARRAY_BUFFER);
  }

  // WebKit bug - the same parent prototype for typed arrays and data view
  if (setPrototypeOf && getPrototypeOf(DataViewPrototype) !== ObjectPrototype) {
    setPrototypeOf(DataViewPrototype, ObjectPrototype);
  }

  // iOS Safari 7.x bug
  var testView = new $DataView(new $ArrayBuffer(2));
  var $setInt8 = uncurryThis(DataViewPrototype.setInt8);
  testView.setInt8(0, 2147483648);
  testView.setInt8(1, 2147483649);
  if (testView.getInt8(0) || !testView.getInt8(1)) defineBuiltIns(DataViewPrototype, {
    setInt8: function setInt8(byteOffset, value) {
      $setInt8(this, byteOffset, value << 24 >> 24);
    },
    setUint8: function setUint8(byteOffset, value) {
      $setInt8(this, byteOffset, value << 24 >> 24);
    }
  }, { unsafe: true });
}

setToStringTag($ArrayBuffer, ARRAY_BUFFER);
setToStringTag($DataView, DATA_VIEW);

module.exports = {
  ArrayBuffer: $ArrayBuffer,
  DataView: $DataView
};


/***/ }),

/***/ 7029:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toObject = __webpack_require__(8981);
var toAbsoluteIndex = __webpack_require__(5610);
var lengthOfArrayLike = __webpack_require__(6198);
var deletePropertyOrThrow = __webpack_require__(4606);

var min = Math.min;

// `Array.prototype.copyWithin` method implementation
// https://tc39.es/ecma262/#sec-array.prototype.copywithin
// eslint-disable-next-line es/no-array-prototype-copywithin -- safe
module.exports = [].copyWithin || function copyWithin(target /* = 0 */, start /* = 0, end = @length */) {
  var O = toObject(this);
  var len = lengthOfArrayLike(O);
  var to = toAbsoluteIndex(target, len);
  var from = toAbsoluteIndex(start, len);
  var end = arguments.length > 2 ? arguments[2] : undefined;
  var count = min((end === undefined ? len : toAbsoluteIndex(end, len)) - from, len - to);
  var inc = 1;
  if (from < to && to < from + count) {
    inc = -1;
    from += count - 1;
    to += count - 1;
  }
  while (count-- > 0) {
    if (from in O) O[to] = O[from];
    else deletePropertyOrThrow(O, to);
    to += inc;
    from += inc;
  } return O;
};


/***/ }),

/***/ 4373:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toObject = __webpack_require__(8981);
var toAbsoluteIndex = __webpack_require__(5610);
var lengthOfArrayLike = __webpack_require__(6198);

// `Array.prototype.fill` method implementation
// https://tc39.es/ecma262/#sec-array.prototype.fill
module.exports = function fill(value /* , start = 0, end = @length */) {
  var O = toObject(this);
  var length = lengthOfArrayLike(O);
  var argumentsLength = arguments.length;
  var index = toAbsoluteIndex(argumentsLength > 1 ? arguments[1] : undefined, length);
  var end = argumentsLength > 2 ? arguments[2] : undefined;
  var endPos = end === undefined ? length : toAbsoluteIndex(end, length);
  while (endPos > index) O[index++] = value;
  return O;
};


/***/ }),

/***/ 235:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var $forEach = (__webpack_require__(9213).forEach);
var arrayMethodIsStrict = __webpack_require__(4598);

var STRICT_METHOD = arrayMethodIsStrict('forEach');

// `Array.prototype.forEach` method implementation
// https://tc39.es/ecma262/#sec-array.prototype.foreach
module.exports = !STRICT_METHOD ? function forEach(callbackfn /* , thisArg */) {
  return $forEach(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined);
// eslint-disable-next-line es/no-array-prototype-foreach -- safe
} : [].forEach;


/***/ }),

/***/ 5370:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var lengthOfArrayLike = __webpack_require__(6198);

module.exports = function (Constructor, list, $length) {
  var index = 0;
  var length = arguments.length > 2 ? $length : lengthOfArrayLike(list);
  var result = new Constructor(length);
  while (length > index) result[index] = list[index++];
  return result;
};


/***/ }),

/***/ 7916:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var bind = __webpack_require__(6080);
var call = __webpack_require__(9565);
var toObject = __webpack_require__(8981);
var callWithSafeIterationClosing = __webpack_require__(6319);
var isArrayIteratorMethod = __webpack_require__(4209);
var isConstructor = __webpack_require__(3517);
var lengthOfArrayLike = __webpack_require__(6198);
var createProperty = __webpack_require__(4659);
var getIterator = __webpack_require__(81);
var getIteratorMethod = __webpack_require__(851);

var $Array = Array;

// `Array.from` method implementation
// https://tc39.es/ecma262/#sec-array.from
module.exports = function from(arrayLike /* , mapfn = undefined, thisArg = undefined */) {
  var O = toObject(arrayLike);
  var IS_CONSTRUCTOR = isConstructor(this);
  var argumentsLength = arguments.length;
  var mapfn = argumentsLength > 1 ? arguments[1] : undefined;
  var mapping = mapfn !== undefined;
  if (mapping) mapfn = bind(mapfn, argumentsLength > 2 ? arguments[2] : undefined);
  var iteratorMethod = getIteratorMethod(O);
  var index = 0;
  var length, result, step, iterator, next, value;
  // if the target is not iterable or it's an array with the default iterator - use a simple case
  if (iteratorMethod && !(this === $Array && isArrayIteratorMethod(iteratorMethod))) {
    iterator = getIterator(O, iteratorMethod);
    next = iterator.next;
    result = IS_CONSTRUCTOR ? new this() : [];
    for (;!(step = call(next, iterator)).done; index++) {
      value = mapping ? callWithSafeIterationClosing(iterator, mapfn, [step.value, index], true) : step.value;
      createProperty(result, index, value);
    }
  } else {
    length = lengthOfArrayLike(O);
    result = IS_CONSTRUCTOR ? new this(length) : $Array(length);
    for (;length > index; index++) {
      value = mapping ? mapfn(O[index], index) : O[index];
      createProperty(result, index, value);
    }
  }
  result.length = index;
  return result;
};


/***/ }),

/***/ 9617:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toIndexedObject = __webpack_require__(5397);
var toAbsoluteIndex = __webpack_require__(5610);
var lengthOfArrayLike = __webpack_require__(6198);

// `Array.prototype.{ indexOf, includes }` methods implementation
var createMethod = function (IS_INCLUDES) {
  return function ($this, el, fromIndex) {
    var O = toIndexedObject($this);
    var length = lengthOfArrayLike(O);
    if (length === 0) return !IS_INCLUDES && -1;
    var index = toAbsoluteIndex(fromIndex, length);
    var value;
    // Array#includes uses SameValueZero equality algorithm
    // eslint-disable-next-line no-self-compare -- NaN check
    if (IS_INCLUDES && el !== el) while (length > index) {
      value = O[index++];
      // eslint-disable-next-line no-self-compare -- NaN check
      if (value !== value) return true;
    // Array#indexOf ignores holes, Array#includes - not
    } else for (;length > index; index++) {
      if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
    } return !IS_INCLUDES && -1;
  };
};

module.exports = {
  // `Array.prototype.includes` method
  // https://tc39.es/ecma262/#sec-array.prototype.includes
  includes: createMethod(true),
  // `Array.prototype.indexOf` method
  // https://tc39.es/ecma262/#sec-array.prototype.indexof
  indexOf: createMethod(false)
};


/***/ }),

/***/ 3839:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var bind = __webpack_require__(6080);
var IndexedObject = __webpack_require__(7055);
var toObject = __webpack_require__(8981);
var lengthOfArrayLike = __webpack_require__(6198);

// `Array.prototype.{ findLast, findLastIndex }` methods implementation
var createMethod = function (TYPE) {
  var IS_FIND_LAST_INDEX = TYPE === 1;
  return function ($this, callbackfn, that) {
    var O = toObject($this);
    var self = IndexedObject(O);
    var index = lengthOfArrayLike(self);
    var boundFunction = bind(callbackfn, that);
    var value, result;
    while (index-- > 0) {
      value = self[index];
      result = boundFunction(value, index, O);
      if (result) switch (TYPE) {
        case 0: return value; // findLast
        case 1: return index; // findLastIndex
      }
    }
    return IS_FIND_LAST_INDEX ? -1 : undefined;
  };
};

module.exports = {
  // `Array.prototype.findLast` method
  // https://github.com/tc39/proposal-array-find-from-last
  findLast: createMethod(0),
  // `Array.prototype.findLastIndex` method
  // https://github.com/tc39/proposal-array-find-from-last
  findLastIndex: createMethod(1)
};


/***/ }),

/***/ 9213:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var bind = __webpack_require__(6080);
var uncurryThis = __webpack_require__(9504);
var IndexedObject = __webpack_require__(7055);
var toObject = __webpack_require__(8981);
var lengthOfArrayLike = __webpack_require__(6198);
var arraySpeciesCreate = __webpack_require__(1469);

var push = uncurryThis([].push);

// `Array.prototype.{ forEach, map, filter, some, every, find, findIndex, filterReject }` methods implementation
var createMethod = function (TYPE) {
  var IS_MAP = TYPE === 1;
  var IS_FILTER = TYPE === 2;
  var IS_SOME = TYPE === 3;
  var IS_EVERY = TYPE === 4;
  var IS_FIND_INDEX = TYPE === 6;
  var IS_FILTER_REJECT = TYPE === 7;
  var NO_HOLES = TYPE === 5 || IS_FIND_INDEX;
  return function ($this, callbackfn, that, specificCreate) {
    var O = toObject($this);
    var self = IndexedObject(O);
    var length = lengthOfArrayLike(self);
    var boundFunction = bind(callbackfn, that);
    var index = 0;
    var create = specificCreate || arraySpeciesCreate;
    var target = IS_MAP ? create($this, length) : IS_FILTER || IS_FILTER_REJECT ? create($this, 0) : undefined;
    var value, result;
    for (;length > index; index++) if (NO_HOLES || index in self) {
      value = self[index];
      result = boundFunction(value, index, O);
      if (TYPE) {
        if (IS_MAP) target[index] = result; // map
        else if (result) switch (TYPE) {
          case 3: return true;              // some
          case 5: return value;             // find
          case 6: return index;             // findIndex
          case 2: push(target, value);      // filter
        } else switch (TYPE) {
          case 4: return false;             // every
          case 7: push(target, value);      // filterReject
        }
      }
    }
    return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target;
  };
};

module.exports = {
  // `Array.prototype.forEach` method
  // https://tc39.es/ecma262/#sec-array.prototype.foreach
  forEach: createMethod(0),
  // `Array.prototype.map` method
  // https://tc39.es/ecma262/#sec-array.prototype.map
  map: createMethod(1),
  // `Array.prototype.filter` method
  // https://tc39.es/ecma262/#sec-array.prototype.filter
  filter: createMethod(2),
  // `Array.prototype.some` method
  // https://tc39.es/ecma262/#sec-array.prototype.some
  some: createMethod(3),
  // `Array.prototype.every` method
  // https://tc39.es/ecma262/#sec-array.prototype.every
  every: createMethod(4),
  // `Array.prototype.find` method
  // https://tc39.es/ecma262/#sec-array.prototype.find
  find: createMethod(5),
  // `Array.prototype.findIndex` method
  // https://tc39.es/ecma262/#sec-array.prototype.findIndex
  findIndex: createMethod(6),
  // `Array.prototype.filterReject` method
  // https://github.com/tc39/proposal-array-filtering
  filterReject: createMethod(7)
};


/***/ }),

/***/ 8379:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable es/no-array-prototype-lastindexof -- safe */
var apply = __webpack_require__(8745);
var toIndexedObject = __webpack_require__(5397);
var toIntegerOrInfinity = __webpack_require__(1291);
var lengthOfArrayLike = __webpack_require__(6198);
var arrayMethodIsStrict = __webpack_require__(4598);

var min = Math.min;
var $lastIndexOf = [].lastIndexOf;
var NEGATIVE_ZERO = !!$lastIndexOf && 1 / [1].lastIndexOf(1, -0) < 0;
var STRICT_METHOD = arrayMethodIsStrict('lastIndexOf');
var FORCED = NEGATIVE_ZERO || !STRICT_METHOD;

// `Array.prototype.lastIndexOf` method implementation
// https://tc39.es/ecma262/#sec-array.prototype.lastindexof
module.exports = FORCED ? function lastIndexOf(searchElement /* , fromIndex = @[*-1] */) {
  // convert -0 to +0
  if (NEGATIVE_ZERO) return apply($lastIndexOf, this, arguments) || 0;
  var O = toIndexedObject(this);
  var length = lengthOfArrayLike(O);
  if (length === 0) return -1;
  var index = length - 1;
  if (arguments.length > 1) index = min(index, toIntegerOrInfinity(arguments[1]));
  if (index < 0) index = length + index;
  for (;index >= 0; index--) if (index in O && O[index] === searchElement) return index || 0;
  return -1;
} : $lastIndexOf;


/***/ }),

/***/ 597:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var wellKnownSymbol = __webpack_require__(8227);
var V8_VERSION = __webpack_require__(7388);

var SPECIES = wellKnownSymbol('species');

module.exports = function (METHOD_NAME) {
  // We can't use this feature detection in V8 since it causes
  // deoptimization and serious performance degradation
  // https://github.com/zloirock/core-js/issues/677
  return V8_VERSION >= 51 || !fails(function () {
    var array = [];
    var constructor = array.constructor = {};
    constructor[SPECIES] = function () {
      return { foo: 1 };
    };
    return array[METHOD_NAME](Boolean).foo !== 1;
  });
};


/***/ }),

/***/ 4598:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);

module.exports = function (METHOD_NAME, argument) {
  var method = [][METHOD_NAME];
  return !!method && fails(function () {
    // eslint-disable-next-line no-useless-call -- required for testing
    method.call(null, argument || function () { return 1; }, 1);
  });
};


/***/ }),

/***/ 926:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var aCallable = __webpack_require__(9306);
var toObject = __webpack_require__(8981);
var IndexedObject = __webpack_require__(7055);
var lengthOfArrayLike = __webpack_require__(6198);

var $TypeError = TypeError;

var REDUCE_EMPTY = 'Reduce of empty array with no initial value';

// `Array.prototype.{ reduce, reduceRight }` methods implementation
var createMethod = function (IS_RIGHT) {
  return function (that, callbackfn, argumentsLength, memo) {
    var O = toObject(that);
    var self = IndexedObject(O);
    var length = lengthOfArrayLike(O);
    aCallable(callbackfn);
    if (length === 0 && argumentsLength < 2) throw new $TypeError(REDUCE_EMPTY);
    var index = IS_RIGHT ? length - 1 : 0;
    var i = IS_RIGHT ? -1 : 1;
    if (argumentsLength < 2) while (true) {
      if (index in self) {
        memo = self[index];
        index += i;
        break;
      }
      index += i;
      if (IS_RIGHT ? index < 0 : length <= index) {
        throw new $TypeError(REDUCE_EMPTY);
      }
    }
    for (;IS_RIGHT ? index >= 0 : length > index; index += i) if (index in self) {
      memo = callbackfn(memo, self[index], index, O);
    }
    return memo;
  };
};

module.exports = {
  // `Array.prototype.reduce` method
  // https://tc39.es/ecma262/#sec-array.prototype.reduce
  left: createMethod(false),
  // `Array.prototype.reduceRight` method
  // https://tc39.es/ecma262/#sec-array.prototype.reduceright
  right: createMethod(true)
};


/***/ }),

/***/ 4527:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var isArray = __webpack_require__(4376);

var $TypeError = TypeError;
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;

// Safari < 13 does not throw an error in this case
var SILENT_ON_NON_WRITABLE_LENGTH_SET = DESCRIPTORS && !function () {
  // makes no sense without proper strict mode support
  if (this !== undefined) return true;
  try {
    // eslint-disable-next-line es/no-object-defineproperty -- safe
    Object.defineProperty([], 'length', { writable: false }).length = 1;
  } catch (error) {
    return error instanceof TypeError;
  }
}();

module.exports = SILENT_ON_NON_WRITABLE_LENGTH_SET ? function (O, length) {
  if (isArray(O) && !getOwnPropertyDescriptor(O, 'length').writable) {
    throw new $TypeError('Cannot set read only .length');
  } return O.length = length;
} : function (O, length) {
  return O.length = length;
};


/***/ }),

/***/ 7680:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);

module.exports = uncurryThis([].slice);


/***/ }),

/***/ 4488:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var arraySlice = __webpack_require__(7680);

var floor = Math.floor;

var sort = function (array, comparefn) {
  var length = array.length;

  if (length < 8) {
    // insertion sort
    var i = 1;
    var element, j;

    while (i < length) {
      j = i;
      element = array[i];
      while (j && comparefn(array[j - 1], element) > 0) {
        array[j] = array[--j];
      }
      if (j !== i++) array[j] = element;
    }
  } else {
    // merge sort
    var middle = floor(length / 2);
    var left = sort(arraySlice(array, 0, middle), comparefn);
    var right = sort(arraySlice(array, middle), comparefn);
    var llength = left.length;
    var rlength = right.length;
    var lindex = 0;
    var rindex = 0;

    while (lindex < llength || rindex < rlength) {
      array[lindex + rindex] = (lindex < llength && rindex < rlength)
        ? comparefn(left[lindex], right[rindex]) <= 0 ? left[lindex++] : right[rindex++]
        : lindex < llength ? left[lindex++] : right[rindex++];
    }
  }

  return array;
};

module.exports = sort;


/***/ }),

/***/ 7433:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isArray = __webpack_require__(4376);
var isConstructor = __webpack_require__(3517);
var isObject = __webpack_require__(34);
var wellKnownSymbol = __webpack_require__(8227);

var SPECIES = wellKnownSymbol('species');
var $Array = Array;

// a part of `ArraySpeciesCreate` abstract operation
// https://tc39.es/ecma262/#sec-arrayspeciescreate
module.exports = function (originalArray) {
  var C;
  if (isArray(originalArray)) {
    C = originalArray.constructor;
    // cross-realm fallback
    if (isConstructor(C) && (C === $Array || isArray(C.prototype))) C = undefined;
    else if (isObject(C)) {
      C = C[SPECIES];
      if (C === null) C = undefined;
    }
  } return C === undefined ? $Array : C;
};


/***/ }),

/***/ 1469:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var arraySpeciesConstructor = __webpack_require__(7433);

// `ArraySpeciesCreate` abstract operation
// https://tc39.es/ecma262/#sec-arrayspeciescreate
module.exports = function (originalArray, length) {
  return new (arraySpeciesConstructor(originalArray))(length === 0 ? 0 : length);
};


/***/ }),

/***/ 7628:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var lengthOfArrayLike = __webpack_require__(6198);

// https://tc39.es/proposal-change-array-by-copy/#sec-array.prototype.toReversed
// https://tc39.es/proposal-change-array-by-copy/#sec-%typedarray%.prototype.toReversed
module.exports = function (O, C) {
  var len = lengthOfArrayLike(O);
  var A = new C(len);
  var k = 0;
  for (; k < len; k++) A[k] = O[len - k - 1];
  return A;
};


/***/ }),

/***/ 9928:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var lengthOfArrayLike = __webpack_require__(6198);
var toIntegerOrInfinity = __webpack_require__(1291);

var $RangeError = RangeError;

// https://tc39.es/proposal-change-array-by-copy/#sec-array.prototype.with
// https://tc39.es/proposal-change-array-by-copy/#sec-%typedarray%.prototype.with
module.exports = function (O, C, index, value) {
  var len = lengthOfArrayLike(O);
  var relativeIndex = toIntegerOrInfinity(index);
  var actualIndex = relativeIndex < 0 ? len + relativeIndex : relativeIndex;
  if (actualIndex >= len || actualIndex < 0) throw new $RangeError('Incorrect index');
  var A = new C(len);
  var k = 0;
  for (; k < len; k++) A[k] = k === actualIndex ? value : O[k];
  return A;
};


/***/ }),

/***/ 6319:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var anObject = __webpack_require__(8551);
var iteratorClose = __webpack_require__(9539);

// call something on iterator step with safe closing on error
module.exports = function (iterator, fn, value, ENTRIES) {
  try {
    return ENTRIES ? fn(anObject(value)[0], value[1]) : fn(value);
  } catch (error) {
    iteratorClose(iterator, 'throw', error);
  }
};


/***/ }),

/***/ 4428:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var wellKnownSymbol = __webpack_require__(8227);

var ITERATOR = wellKnownSymbol('iterator');
var SAFE_CLOSING = false;

try {
  var called = 0;
  var iteratorWithReturn = {
    next: function () {
      return { done: !!called++ };
    },
    'return': function () {
      SAFE_CLOSING = true;
    }
  };
  iteratorWithReturn[ITERATOR] = function () {
    return this;
  };
  // eslint-disable-next-line es/no-array-from, no-throw-literal -- required for testing
  Array.from(iteratorWithReturn, function () { throw 2; });
} catch (error) { /* empty */ }

module.exports = function (exec, SKIP_CLOSING) {
  try {
    if (!SKIP_CLOSING && !SAFE_CLOSING) return false;
  } catch (error) { return false; } // workaround of old WebKit + `eval` bug
  var ITERATION_SUPPORT = false;
  try {
    var object = {};
    object[ITERATOR] = function () {
      return {
        next: function () {
          return { done: ITERATION_SUPPORT = true };
        }
      };
    };
    exec(object);
  } catch (error) { /* empty */ }
  return ITERATION_SUPPORT;
};


/***/ }),

/***/ 4576:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);

var toString = uncurryThis({}.toString);
var stringSlice = uncurryThis(''.slice);

module.exports = function (it) {
  return stringSlice(toString(it), 8, -1);
};


/***/ }),

/***/ 6955:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var TO_STRING_TAG_SUPPORT = __webpack_require__(2140);
var isCallable = __webpack_require__(4901);
var classofRaw = __webpack_require__(4576);
var wellKnownSymbol = __webpack_require__(8227);

var TO_STRING_TAG = wellKnownSymbol('toStringTag');
var $Object = Object;

// ES3 wrong here
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';

// fallback for IE11 Script Access Denied error
var tryGet = function (it, key) {
  try {
    return it[key];
  } catch (error) { /* empty */ }
};

// getting tag from ES6+ `Object.prototype.toString`
module.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
  var O, tag, result;
  return it === undefined ? 'Undefined' : it === null ? 'Null'
    // @@toStringTag case
    : typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag
    // builtinTag case
    : CORRECT_ARGUMENTS ? classofRaw(O)
    // ES3 arguments fallback
    : (result = classofRaw(O)) === 'Object' && isCallable(O.callee) ? 'Arguments' : result;
};


/***/ }),

/***/ 7740:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var hasOwn = __webpack_require__(9297);
var ownKeys = __webpack_require__(5031);
var getOwnPropertyDescriptorModule = __webpack_require__(7347);
var definePropertyModule = __webpack_require__(4913);

module.exports = function (target, source, exceptions) {
  var keys = ownKeys(source);
  var defineProperty = definePropertyModule.f;
  var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
  for (var i = 0; i < keys.length; i++) {
    var key = keys[i];
    if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) {
      defineProperty(target, key, getOwnPropertyDescriptor(source, key));
    }
  }
};


/***/ }),

/***/ 1436:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var wellKnownSymbol = __webpack_require__(8227);

var MATCH = wellKnownSymbol('match');

module.exports = function (METHOD_NAME) {
  var regexp = /./;
  try {
    '/./'[METHOD_NAME](regexp);
  } catch (error1) {
    try {
      regexp[MATCH] = false;
      return '/./'[METHOD_NAME](regexp);
    } catch (error2) { /* empty */ }
  } return false;
};


/***/ }),

/***/ 2211:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);

module.exports = !fails(function () {
  function F() { /* empty */ }
  F.prototype.constructor = null;
  // eslint-disable-next-line es/no-object-getprototypeof -- required for testing
  return Object.getPrototypeOf(new F()) !== F.prototype;
});


/***/ }),

/***/ 2529:
/***/ (function(module) {


// `CreateIterResultObject` abstract operation
// https://tc39.es/ecma262/#sec-createiterresultobject
module.exports = function (value, done) {
  return { value: value, done: done };
};


/***/ }),

/***/ 6699:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var definePropertyModule = __webpack_require__(4913);
var createPropertyDescriptor = __webpack_require__(6980);

module.exports = DESCRIPTORS ? function (object, key, value) {
  return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));
} : function (object, key, value) {
  object[key] = value;
  return object;
};


/***/ }),

/***/ 6980:
/***/ (function(module) {


module.exports = function (bitmap, value) {
  return {
    enumerable: !(bitmap & 1),
    configurable: !(bitmap & 2),
    writable: !(bitmap & 4),
    value: value
  };
};


/***/ }),

/***/ 4659:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var definePropertyModule = __webpack_require__(4913);
var createPropertyDescriptor = __webpack_require__(6980);

module.exports = function (object, key, value) {
  if (DESCRIPTORS) definePropertyModule.f(object, key, createPropertyDescriptor(0, value));
  else object[key] = value;
};


/***/ }),

/***/ 3640:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var anObject = __webpack_require__(8551);
var ordinaryToPrimitive = __webpack_require__(4270);

var $TypeError = TypeError;

// `Date.prototype[@@toPrimitive](hint)` method implementation
// https://tc39.es/ecma262/#sec-date.prototype-@@toprimitive
module.exports = function (hint) {
  anObject(this);
  if (hint === 'string' || hint === 'default') hint = 'string';
  else if (hint !== 'number') throw new $TypeError('Incorrect hint');
  return ordinaryToPrimitive(this, hint);
};


/***/ }),

/***/ 2106:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var makeBuiltIn = __webpack_require__(283);
var defineProperty = __webpack_require__(4913);

module.exports = function (target, name, descriptor) {
  if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
  if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
  return defineProperty.f(target, name, descriptor);
};


/***/ }),

/***/ 6840:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isCallable = __webpack_require__(4901);
var definePropertyModule = __webpack_require__(4913);
var makeBuiltIn = __webpack_require__(283);
var defineGlobalProperty = __webpack_require__(9433);

module.exports = function (O, key, value, options) {
  if (!options) options = {};
  var simple = options.enumerable;
  var name = options.name !== undefined ? options.name : key;
  if (isCallable(value)) makeBuiltIn(value, name, options);
  if (options.global) {
    if (simple) O[key] = value;
    else defineGlobalProperty(key, value);
  } else {
    try {
      if (!options.unsafe) delete O[key];
      else if (O[key]) simple = true;
    } catch (error) { /* empty */ }
    if (simple) O[key] = value;
    else definePropertyModule.f(O, key, {
      value: value,
      enumerable: false,
      configurable: !options.nonConfigurable,
      writable: !options.nonWritable
    });
  } return O;
};


/***/ }),

/***/ 6279:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var defineBuiltIn = __webpack_require__(6840);

module.exports = function (target, src, options) {
  for (var key in src) defineBuiltIn(target, key, src[key], options);
  return target;
};


/***/ }),

/***/ 9433:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);

// eslint-disable-next-line es/no-object-defineproperty -- safe
var defineProperty = Object.defineProperty;

module.exports = function (key, value) {
  try {
    defineProperty(global, key, { value: value, configurable: true, writable: true });
  } catch (error) {
    global[key] = value;
  } return value;
};


/***/ }),

/***/ 4606:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var tryToString = __webpack_require__(6823);

var $TypeError = TypeError;

module.exports = function (O, P) {
  if (!delete O[P]) throw new $TypeError('Cannot delete property ' + tryToString(P) + ' of ' + tryToString(O));
};


/***/ }),

/***/ 3724:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);

// Detect IE8's incomplete defineProperty implementation
module.exports = !fails(function () {
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
  return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
});


/***/ }),

/***/ 4483:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var tryNodeRequire = __webpack_require__(9714);
var PROPER_STRUCTURED_CLONE_TRANSFER = __webpack_require__(1548);

var structuredClone = global.structuredClone;
var $ArrayBuffer = global.ArrayBuffer;
var $MessageChannel = global.MessageChannel;
var detach = false;
var WorkerThreads, channel, buffer, $detach;

if (PROPER_STRUCTURED_CLONE_TRANSFER) {
  detach = function (transferable) {
    structuredClone(transferable, { transfer: [transferable] });
  };
} else if ($ArrayBuffer) try {
  if (!$MessageChannel) {
    WorkerThreads = tryNodeRequire('worker_threads');
    if (WorkerThreads) $MessageChannel = WorkerThreads.MessageChannel;
  }

  if ($MessageChannel) {
    channel = new $MessageChannel();
    buffer = new $ArrayBuffer(2);

    $detach = function (transferable) {
      channel.port1.postMessage(null, [transferable]);
    };

    if (buffer.byteLength === 2) {
      $detach(buffer);
      if (buffer.byteLength === 0) detach = $detach;
    }
  }
} catch (error) { /* empty */ }

module.exports = detach;


/***/ }),

/***/ 4055:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var isObject = __webpack_require__(34);

var document = global.document;
// typeof document.createElement is 'object' in old IE
var EXISTS = isObject(document) && isObject(document.createElement);

module.exports = function (it) {
  return EXISTS ? document.createElement(it) : {};
};


/***/ }),

/***/ 6837:
/***/ (function(module) {


var $TypeError = TypeError;
var MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991

module.exports = function (it) {
  if (it > MAX_SAFE_INTEGER) throw $TypeError('Maximum allowed index exceeded');
  return it;
};


/***/ }),

/***/ 7400:
/***/ (function(module) {


// iterable DOM collections
// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods
module.exports = {
  CSSRuleList: 0,
  CSSStyleDeclaration: 0,
  CSSValueList: 0,
  ClientRectList: 0,
  DOMRectList: 0,
  DOMStringList: 0,
  DOMTokenList: 1,
  DataTransferItemList: 0,
  FileList: 0,
  HTMLAllCollection: 0,
  HTMLCollection: 0,
  HTMLFormElement: 0,
  HTMLSelectElement: 0,
  MediaList: 0,
  MimeTypeArray: 0,
  NamedNodeMap: 0,
  NodeList: 1,
  PaintRequestList: 0,
  Plugin: 0,
  PluginArray: 0,
  SVGLengthList: 0,
  SVGNumberList: 0,
  SVGPathSegList: 0,
  SVGPointList: 0,
  SVGStringList: 0,
  SVGTransformList: 0,
  SourceBufferList: 0,
  StyleSheetList: 0,
  TextTrackCueList: 0,
  TextTrackList: 0,
  TouchList: 0
};


/***/ }),

/***/ 9296:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


// in old WebKit versions, `element.classList` is not an instance of global `DOMTokenList`
var documentCreateElement = __webpack_require__(4055);

var classList = documentCreateElement('span').classList;
var DOMTokenListPrototype = classList && classList.constructor && classList.constructor.prototype;

module.exports = DOMTokenListPrototype === Object.prototype ? undefined : DOMTokenListPrototype;


/***/ }),

/***/ 8834:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var userAgent = __webpack_require__(9392);

var firefox = userAgent.match(/firefox\/(\d+)/i);

module.exports = !!firefox && +firefox[1];


/***/ }),

/***/ 7290:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var IS_DENO = __webpack_require__(516);
var IS_NODE = __webpack_require__(9088);

module.exports = !IS_DENO && !IS_NODE
  && typeof window == 'object'
  && typeof document == 'object';


/***/ }),

/***/ 516:
/***/ (function(module) {


/* global Deno -- Deno case */
module.exports = typeof Deno == 'object' && Deno && typeof Deno.version == 'object';


/***/ }),

/***/ 3202:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var UA = __webpack_require__(9392);

module.exports = /MSIE|Trident/.test(UA);


/***/ }),

/***/ 28:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var userAgent = __webpack_require__(9392);

module.exports = /ipad|iphone|ipod/i.test(userAgent) && typeof Pebble != 'undefined';


/***/ }),

/***/ 8119:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var userAgent = __webpack_require__(9392);

// eslint-disable-next-line redos/no-vulnerable -- safe
module.exports = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent);


/***/ }),

/***/ 9088:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var classof = __webpack_require__(4576);

module.exports = classof(global.process) === 'process';


/***/ }),

/***/ 6765:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var userAgent = __webpack_require__(9392);

module.exports = /web0s(?!.*chrome)/i.test(userAgent);


/***/ }),

/***/ 9392:
/***/ (function(module) {


module.exports = typeof navigator != 'undefined' && String(navigator.userAgent) || '';


/***/ }),

/***/ 7388:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var userAgent = __webpack_require__(9392);

var process = global.process;
var Deno = global.Deno;
var versions = process && process.versions || Deno && Deno.version;
var v8 = versions && versions.v8;
var match, version;

if (v8) {
  match = v8.split('.');
  // in old Chrome, versions of V8 isn't V8 = Chrome / 10
  // but their correct versions are not interesting for us
  version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
}

// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
// so check `userAgent` even if `.v8` exists, but 0
if (!version && userAgent) {
  match = userAgent.match(/Edge\/(\d+)/);
  if (!match || match[1] >= 74) {
    match = userAgent.match(/Chrome\/(\d+)/);
    if (match) version = +match[1];
  }
}

module.exports = version;


/***/ }),

/***/ 9160:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var userAgent = __webpack_require__(9392);

var webkit = userAgent.match(/AppleWebKit\/(\d+)\./);

module.exports = !!webkit && +webkit[1];


/***/ }),

/***/ 8727:
/***/ (function(module) {


// IE8- don't enum bug keys
module.exports = [
  'constructor',
  'hasOwnProperty',
  'isPrototypeOf',
  'propertyIsEnumerable',
  'toLocaleString',
  'toString',
  'valueOf'
];


/***/ }),

/***/ 6193:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);

var $Error = Error;
var replace = uncurryThis(''.replace);

var TEST = (function (arg) { return String(new $Error(arg).stack); })('zxcasd');
// eslint-disable-next-line redos/no-vulnerable -- safe
var V8_OR_CHAKRA_STACK_ENTRY = /\n\s*at [^:]*:[^\n]*/;
var IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST);

module.exports = function (stack, dropEntries) {
  if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string' && !$Error.prepareStackTrace) {
    while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, '');
  } return stack;
};


/***/ }),

/***/ 747:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var createNonEnumerableProperty = __webpack_require__(6699);
var clearErrorStack = __webpack_require__(6193);
var ERROR_STACK_INSTALLABLE = __webpack_require__(6249);

// non-standard V8
var captureStackTrace = Error.captureStackTrace;

module.exports = function (error, C, stack, dropEntries) {
  if (ERROR_STACK_INSTALLABLE) {
    if (captureStackTrace) captureStackTrace(error, C);
    else createNonEnumerableProperty(error, 'stack', clearErrorStack(stack, dropEntries));
  }
};


/***/ }),

/***/ 6249:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var createPropertyDescriptor = __webpack_require__(6980);

module.exports = !fails(function () {
  var error = new Error('a');
  if (!('stack' in error)) return true;
  // eslint-disable-next-line es/no-object-defineproperty -- safe
  Object.defineProperty(error, 'stack', createPropertyDescriptor(1, 7));
  return error.stack !== 7;
});


/***/ }),

/***/ 6518:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var getOwnPropertyDescriptor = (__webpack_require__(7347).f);
var createNonEnumerableProperty = __webpack_require__(6699);
var defineBuiltIn = __webpack_require__(6840);
var defineGlobalProperty = __webpack_require__(9433);
var copyConstructorProperties = __webpack_require__(7740);
var isForced = __webpack_require__(2796);

/*
  options.target         - name of the target object
  options.global         - target is the global object
  options.stat           - export as static methods of target
  options.proto          - export as prototype methods of target
  options.real           - real prototype method for the `pure` version
  options.forced         - export even if the native feature is available
  options.bind           - bind methods to the target, required for the `pure` version
  options.wrap           - wrap constructors to preventing global pollution, required for the `pure` version
  options.unsafe         - use the simple assignment of property instead of delete + defineProperty
  options.sham           - add a flag to not completely full polyfills
  options.enumerable     - export as enumerable property
  options.dontCallGetSet - prevent calling a getter on target
  options.name           - the .name of the function if it does not match the key
*/
module.exports = function (options, source) {
  var TARGET = options.target;
  var GLOBAL = options.global;
  var STATIC = options.stat;
  var FORCED, target, key, targetProperty, sourceProperty, descriptor;
  if (GLOBAL) {
    target = global;
  } else if (STATIC) {
    target = global[TARGET] || defineGlobalProperty(TARGET, {});
  } else {
    target = global[TARGET] && global[TARGET].prototype;
  }
  if (target) for (key in source) {
    sourceProperty = source[key];
    if (options.dontCallGetSet) {
      descriptor = getOwnPropertyDescriptor(target, key);
      targetProperty = descriptor && descriptor.value;
    } else targetProperty = target[key];
    FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
    // contained in target
    if (!FORCED && targetProperty !== undefined) {
      if (typeof sourceProperty == typeof targetProperty) continue;
      copyConstructorProperties(sourceProperty, targetProperty);
    }
    // add a flag to not completely full polyfills
    if (options.sham || (targetProperty && targetProperty.sham)) {
      createNonEnumerableProperty(sourceProperty, 'sham', true);
    }
    defineBuiltIn(target, key, sourceProperty, options);
  }
};


/***/ }),

/***/ 9039:
/***/ (function(module) {


module.exports = function (exec) {
  try {
    return !!exec();
  } catch (error) {
    return true;
  }
};


/***/ }),

/***/ 9228:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove from `core-js@4` since it's moved to entry points
__webpack_require__(7495);
var call = __webpack_require__(9565);
var defineBuiltIn = __webpack_require__(6840);
var regexpExec = __webpack_require__(7323);
var fails = __webpack_require__(9039);
var wellKnownSymbol = __webpack_require__(8227);
var createNonEnumerableProperty = __webpack_require__(6699);

var SPECIES = wellKnownSymbol('species');
var RegExpPrototype = RegExp.prototype;

module.exports = function (KEY, exec, FORCED, SHAM) {
  var SYMBOL = wellKnownSymbol(KEY);

  var DELEGATES_TO_SYMBOL = !fails(function () {
    // String methods call symbol-named RegExp methods
    var O = {};
    O[SYMBOL] = function () { return 7; };
    return ''[KEY](O) !== 7;
  });

  var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails(function () {
    // Symbol-named RegExp methods call .exec
    var execCalled = false;
    var re = /a/;

    if (KEY === 'split') {
      // We can't use real regex here since it causes deoptimization
      // and serious performance degradation in V8
      // https://github.com/zloirock/core-js/issues/306
      re = {};
      // RegExp[@@split] doesn't call the regex's exec method, but first creates
      // a new one. We need to return the patched regex when creating the new one.
      re.constructor = {};
      re.constructor[SPECIES] = function () { return re; };
      re.flags = '';
      re[SYMBOL] = /./[SYMBOL];
    }

    re.exec = function () {
      execCalled = true;
      return null;
    };

    re[SYMBOL]('');
    return !execCalled;
  });

  if (
    !DELEGATES_TO_SYMBOL ||
    !DELEGATES_TO_EXEC ||
    FORCED
  ) {
    var nativeRegExpMethod = /./[SYMBOL];
    var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {
      var $exec = regexp.exec;
      if ($exec === regexpExec || $exec === RegExpPrototype.exec) {
        if (DELEGATES_TO_SYMBOL && !forceStringMethod) {
          // The native String method already delegates to @@method (this
          // polyfilled function), leasing to infinite recursion.
          // We avoid it by directly calling the native @@method method.
          return { done: true, value: call(nativeRegExpMethod, regexp, str, arg2) };
        }
        return { done: true, value: call(nativeMethod, str, regexp, arg2) };
      }
      return { done: false };
    });

    defineBuiltIn(String.prototype, KEY, methods[0]);
    defineBuiltIn(RegExpPrototype, SYMBOL, methods[1]);
  }

  if (SHAM) createNonEnumerableProperty(RegExpPrototype[SYMBOL], 'sham', true);
};


/***/ }),

/***/ 2744:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);

module.exports = !fails(function () {
  // eslint-disable-next-line es/no-object-isextensible, es/no-object-preventextensions -- required for testing
  return Object.isExtensible(Object.preventExtensions({}));
});


/***/ }),

/***/ 8745:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var NATIVE_BIND = __webpack_require__(616);

var FunctionPrototype = Function.prototype;
var apply = FunctionPrototype.apply;
var call = FunctionPrototype.call;

// eslint-disable-next-line es/no-reflect -- safe
module.exports = typeof Reflect == 'object' && Reflect.apply || (NATIVE_BIND ? call.bind(apply) : function () {
  return call.apply(apply, arguments);
});


/***/ }),

/***/ 6080:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(7476);
var aCallable = __webpack_require__(9306);
var NATIVE_BIND = __webpack_require__(616);

var bind = uncurryThis(uncurryThis.bind);

// optional / simple context binding
module.exports = function (fn, that) {
  aCallable(fn);
  return that === undefined ? fn : NATIVE_BIND ? bind(fn, that) : function (/* ...args */) {
    return fn.apply(that, arguments);
  };
};


/***/ }),

/***/ 616:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);

module.exports = !fails(function () {
  // eslint-disable-next-line es/no-function-prototype-bind -- safe
  var test = (function () { /* empty */ }).bind();
  // eslint-disable-next-line no-prototype-builtins -- safe
  return typeof test != 'function' || test.hasOwnProperty('prototype');
});


/***/ }),

/***/ 566:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var aCallable = __webpack_require__(9306);
var isObject = __webpack_require__(34);
var hasOwn = __webpack_require__(9297);
var arraySlice = __webpack_require__(7680);
var NATIVE_BIND = __webpack_require__(616);

var $Function = Function;
var concat = uncurryThis([].concat);
var join = uncurryThis([].join);
var factories = {};

var construct = function (C, argsLength, args) {
  if (!hasOwn(factories, argsLength)) {
    var list = [];
    var i = 0;
    for (; i < argsLength; i++) list[i] = 'a[' + i + ']';
    factories[argsLength] = $Function('C,a', 'return new C(' + join(list, ',') + ')');
  } return factories[argsLength](C, args);
};

// `Function.prototype.bind` method implementation
// https://tc39.es/ecma262/#sec-function.prototype.bind
// eslint-disable-next-line es/no-function-prototype-bind -- detection
module.exports = NATIVE_BIND ? $Function.bind : function bind(that /* , ...args */) {
  var F = aCallable(this);
  var Prototype = F.prototype;
  var partArgs = arraySlice(arguments, 1);
  var boundFunction = function bound(/* args... */) {
    var args = concat(partArgs, arraySlice(arguments));
    return this instanceof boundFunction ? construct(F, args.length, args) : F.apply(that, args);
  };
  if (isObject(Prototype)) boundFunction.prototype = Prototype;
  return boundFunction;
};


/***/ }),

/***/ 9565:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var NATIVE_BIND = __webpack_require__(616);

var call = Function.prototype.call;

module.exports = NATIVE_BIND ? call.bind(call) : function () {
  return call.apply(call, arguments);
};


/***/ }),

/***/ 350:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var hasOwn = __webpack_require__(9297);

var FunctionPrototype = Function.prototype;
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;

var EXISTS = hasOwn(FunctionPrototype, 'name');
// additional protection from minified / mangled / dropped function names
var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
var CONFIGURABLE = EXISTS && (!DESCRIPTORS || (DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable));

module.exports = {
  EXISTS: EXISTS,
  PROPER: PROPER,
  CONFIGURABLE: CONFIGURABLE
};


/***/ }),

/***/ 6706:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var aCallable = __webpack_require__(9306);

module.exports = function (object, key, method) {
  try {
    // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
    return uncurryThis(aCallable(Object.getOwnPropertyDescriptor(object, key)[method]));
  } catch (error) { /* empty */ }
};


/***/ }),

/***/ 7476:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var classofRaw = __webpack_require__(4576);
var uncurryThis = __webpack_require__(9504);

module.exports = function (fn) {
  // Nashorn bug:
  //   https://github.com/zloirock/core-js/issues/1128
  //   https://github.com/zloirock/core-js/issues/1130
  if (classofRaw(fn) === 'Function') return uncurryThis(fn);
};


/***/ }),

/***/ 9504:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var NATIVE_BIND = __webpack_require__(616);

var FunctionPrototype = Function.prototype;
var call = FunctionPrototype.call;
var uncurryThisWithBind = NATIVE_BIND && FunctionPrototype.bind.bind(call, call);

module.exports = NATIVE_BIND ? uncurryThisWithBind : function (fn) {
  return function () {
    return call.apply(fn, arguments);
  };
};


/***/ }),

/***/ 7751:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var isCallable = __webpack_require__(4901);

var aFunction = function (argument) {
  return isCallable(argument) ? argument : undefined;
};

module.exports = function (namespace, method) {
  return arguments.length < 2 ? aFunction(global[namespace]) : global[namespace] && global[namespace][method];
};


/***/ }),

/***/ 851:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var classof = __webpack_require__(6955);
var getMethod = __webpack_require__(5966);
var isNullOrUndefined = __webpack_require__(4117);
var Iterators = __webpack_require__(6269);
var wellKnownSymbol = __webpack_require__(8227);

var ITERATOR = wellKnownSymbol('iterator');

module.exports = function (it) {
  if (!isNullOrUndefined(it)) return getMethod(it, ITERATOR)
    || getMethod(it, '@@iterator')
    || Iterators[classof(it)];
};


/***/ }),

/***/ 81:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var call = __webpack_require__(9565);
var aCallable = __webpack_require__(9306);
var anObject = __webpack_require__(8551);
var tryToString = __webpack_require__(6823);
var getIteratorMethod = __webpack_require__(851);

var $TypeError = TypeError;

module.exports = function (argument, usingIterator) {
  var iteratorMethod = arguments.length < 2 ? getIteratorMethod(argument) : usingIterator;
  if (aCallable(iteratorMethod)) return anObject(call(iteratorMethod, argument));
  throw new $TypeError(tryToString(argument) + ' is not iterable');
};


/***/ }),

/***/ 6933:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var isArray = __webpack_require__(4376);
var isCallable = __webpack_require__(4901);
var classof = __webpack_require__(4576);
var toString = __webpack_require__(655);

var push = uncurryThis([].push);

module.exports = function (replacer) {
  if (isCallable(replacer)) return replacer;
  if (!isArray(replacer)) return;
  var rawLength = replacer.length;
  var keys = [];
  for (var i = 0; i < rawLength; i++) {
    var element = replacer[i];
    if (typeof element == 'string') push(keys, element);
    else if (typeof element == 'number' || classof(element) === 'Number' || classof(element) === 'String') push(keys, toString(element));
  }
  var keysLength = keys.length;
  var root = true;
  return function (key, value) {
    if (root) {
      root = false;
      return value;
    }
    if (isArray(this)) return value;
    for (var j = 0; j < keysLength; j++) if (keys[j] === key) return value;
  };
};


/***/ }),

/***/ 5966:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var aCallable = __webpack_require__(9306);
var isNullOrUndefined = __webpack_require__(4117);

// `GetMethod` abstract operation
// https://tc39.es/ecma262/#sec-getmethod
module.exports = function (V, P) {
  var func = V[P];
  return isNullOrUndefined(func) ? undefined : aCallable(func);
};


/***/ }),

/***/ 2478:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var toObject = __webpack_require__(8981);

var floor = Math.floor;
var charAt = uncurryThis(''.charAt);
var replace = uncurryThis(''.replace);
var stringSlice = uncurryThis(''.slice);
// eslint-disable-next-line redos/no-vulnerable -- safe
var SUBSTITUTION_SYMBOLS = /\$([$&'`]|\d{1,2}|<[^>]*>)/g;
var SUBSTITUTION_SYMBOLS_NO_NAMED = /\$([$&'`]|\d{1,2})/g;

// `GetSubstitution` abstract operation
// https://tc39.es/ecma262/#sec-getsubstitution
module.exports = function (matched, str, position, captures, namedCaptures, replacement) {
  var tailPos = position + matched.length;
  var m = captures.length;
  var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;
  if (namedCaptures !== undefined) {
    namedCaptures = toObject(namedCaptures);
    symbols = SUBSTITUTION_SYMBOLS;
  }
  return replace(replacement, symbols, function (match, ch) {
    var capture;
    switch (charAt(ch, 0)) {
      case '$': return '$';
      case '&': return matched;
      case '`': return stringSlice(str, 0, position);
      case "'": return stringSlice(str, tailPos);
      case '<':
        capture = namedCaptures[stringSlice(ch, 1, -1)];
        break;
      default: // \d\d?
        var n = +ch;
        if (n === 0) return match;
        if (n > m) {
          var f = floor(n / 10);
          if (f === 0) return match;
          if (f <= m) return captures[f - 1] === undefined ? charAt(ch, 1) : captures[f - 1] + charAt(ch, 1);
          return match;
        }
        capture = captures[n - 1];
    }
    return capture === undefined ? '' : capture;
  });
};


/***/ }),

/***/ 4475:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var check = function (it) {
  return it && it.Math === Math && it;
};

// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
module.exports =
  // eslint-disable-next-line es/no-global-this -- safe
  check(typeof globalThis == 'object' && globalThis) ||
  check(typeof window == 'object' && window) ||
  // eslint-disable-next-line no-restricted-globals -- safe
  check(typeof self == 'object' && self) ||
  check(typeof __webpack_require__.g == 'object' && __webpack_require__.g) ||
  check(typeof this == 'object' && this) ||
  // eslint-disable-next-line no-new-func -- fallback
  (function () { return this; })() || Function('return this')();


/***/ }),

/***/ 9297:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var toObject = __webpack_require__(8981);

var hasOwnProperty = uncurryThis({}.hasOwnProperty);

// `HasOwnProperty` abstract operation
// https://tc39.es/ecma262/#sec-hasownproperty
// eslint-disable-next-line es/no-object-hasown -- safe
module.exports = Object.hasOwn || function hasOwn(it, key) {
  return hasOwnProperty(toObject(it), key);
};


/***/ }),

/***/ 421:
/***/ (function(module) {


module.exports = {};


/***/ }),

/***/ 3138:
/***/ (function(module) {


module.exports = function (a, b) {
  try {
    // eslint-disable-next-line no-console -- safe
    arguments.length === 1 ? console.error(a) : console.error(a, b);
  } catch (error) { /* empty */ }
};


/***/ }),

/***/ 397:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var getBuiltIn = __webpack_require__(7751);

module.exports = getBuiltIn('document', 'documentElement');


/***/ }),

/***/ 5917:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var fails = __webpack_require__(9039);
var createElement = __webpack_require__(4055);

// Thanks to IE8 for its funny defineProperty
module.exports = !DESCRIPTORS && !fails(function () {
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
  return Object.defineProperty(createElement('div'), 'a', {
    get: function () { return 7; }
  }).a !== 7;
});


/***/ }),

/***/ 8490:
/***/ (function(module) {


// IEEE754 conversions based on https://github.com/feross/ieee754
var $Array = Array;
var abs = Math.abs;
var pow = Math.pow;
var floor = Math.floor;
var log = Math.log;
var LN2 = Math.LN2;

var pack = function (number, mantissaLength, bytes) {
  var buffer = $Array(bytes);
  var exponentLength = bytes * 8 - mantissaLength - 1;
  var eMax = (1 << exponentLength) - 1;
  var eBias = eMax >> 1;
  var rt = mantissaLength === 23 ? pow(2, -24) - pow(2, -77) : 0;
  var sign = number < 0 || number === 0 && 1 / number < 0 ? 1 : 0;
  var index = 0;
  var exponent, mantissa, c;
  number = abs(number);
  // eslint-disable-next-line no-self-compare -- NaN check
  if (number !== number || number === Infinity) {
    // eslint-disable-next-line no-self-compare -- NaN check
    mantissa = number !== number ? 1 : 0;
    exponent = eMax;
  } else {
    exponent = floor(log(number) / LN2);
    c = pow(2, -exponent);
    if (number * c < 1) {
      exponent--;
      c *= 2;
    }
    if (exponent + eBias >= 1) {
      number += rt / c;
    } else {
      number += rt * pow(2, 1 - eBias);
    }
    if (number * c >= 2) {
      exponent++;
      c /= 2;
    }
    if (exponent + eBias >= eMax) {
      mantissa = 0;
      exponent = eMax;
    } else if (exponent + eBias >= 1) {
      mantissa = (number * c - 1) * pow(2, mantissaLength);
      exponent += eBias;
    } else {
      mantissa = number * pow(2, eBias - 1) * pow(2, mantissaLength);
      exponent = 0;
    }
  }
  while (mantissaLength >= 8) {
    buffer[index++] = mantissa & 255;
    mantissa /= 256;
    mantissaLength -= 8;
  }
  exponent = exponent << mantissaLength | mantissa;
  exponentLength += mantissaLength;
  while (exponentLength > 0) {
    buffer[index++] = exponent & 255;
    exponent /= 256;
    exponentLength -= 8;
  }
  buffer[--index] |= sign * 128;
  return buffer;
};

var unpack = function (buffer, mantissaLength) {
  var bytes = buffer.length;
  var exponentLength = bytes * 8 - mantissaLength - 1;
  var eMax = (1 << exponentLength) - 1;
  var eBias = eMax >> 1;
  var nBits = exponentLength - 7;
  var index = bytes - 1;
  var sign = buffer[index--];
  var exponent = sign & 127;
  var mantissa;
  sign >>= 7;
  while (nBits > 0) {
    exponent = exponent * 256 + buffer[index--];
    nBits -= 8;
  }
  mantissa = exponent & (1 << -nBits) - 1;
  exponent >>= -nBits;
  nBits += mantissaLength;
  while (nBits > 0) {
    mantissa = mantissa * 256 + buffer[index--];
    nBits -= 8;
  }
  if (exponent === 0) {
    exponent = 1 - eBias;
  } else if (exponent === eMax) {
    return mantissa ? NaN : sign ? -Infinity : Infinity;
  } else {
    mantissa += pow(2, mantissaLength);
    exponent -= eBias;
  } return (sign ? -1 : 1) * mantissa * pow(2, exponent - mantissaLength);
};

module.exports = {
  pack: pack,
  unpack: unpack
};


/***/ }),

/***/ 7055:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var fails = __webpack_require__(9039);
var classof = __webpack_require__(4576);

var $Object = Object;
var split = uncurryThis(''.split);

// fallback for non-array-like ES3 and non-enumerable old V8 strings
module.exports = fails(function () {
  // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
  // eslint-disable-next-line no-prototype-builtins -- safe
  return !$Object('z').propertyIsEnumerable(0);
}) ? function (it) {
  return classof(it) === 'String' ? split(it, '') : $Object(it);
} : $Object;


/***/ }),

/***/ 3167:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isCallable = __webpack_require__(4901);
var isObject = __webpack_require__(34);
var setPrototypeOf = __webpack_require__(2967);

// makes subclassing work correct for wrapped built-ins
module.exports = function ($this, dummy, Wrapper) {
  var NewTarget, NewTargetPrototype;
  if (
    // it can work only with native `setPrototypeOf`
    setPrototypeOf &&
    // we haven't completely correct pre-ES6 way for getting `new.target`, so use this
    isCallable(NewTarget = dummy.constructor) &&
    NewTarget !== Wrapper &&
    isObject(NewTargetPrototype = NewTarget.prototype) &&
    NewTargetPrototype !== Wrapper.prototype
  ) setPrototypeOf($this, NewTargetPrototype);
  return $this;
};


/***/ }),

/***/ 3706:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var isCallable = __webpack_require__(4901);
var store = __webpack_require__(7629);

var functionToString = uncurryThis(Function.toString);

// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper
if (!isCallable(store.inspectSource)) {
  store.inspectSource = function (it) {
    return functionToString(it);
  };
}

module.exports = store.inspectSource;


/***/ }),

/***/ 7584:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isObject = __webpack_require__(34);
var createNonEnumerableProperty = __webpack_require__(6699);

// `InstallErrorCause` abstract operation
// https://tc39.es/proposal-error-cause/#sec-errorobjects-install-error-cause
module.exports = function (O, options) {
  if (isObject(options) && 'cause' in options) {
    createNonEnumerableProperty(O, 'cause', options.cause);
  }
};


/***/ }),

/***/ 3451:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var uncurryThis = __webpack_require__(9504);
var hiddenKeys = __webpack_require__(421);
var isObject = __webpack_require__(34);
var hasOwn = __webpack_require__(9297);
var defineProperty = (__webpack_require__(4913).f);
var getOwnPropertyNamesModule = __webpack_require__(8480);
var getOwnPropertyNamesExternalModule = __webpack_require__(298);
var isExtensible = __webpack_require__(4124);
var uid = __webpack_require__(3392);
var FREEZING = __webpack_require__(2744);

var REQUIRED = false;
var METADATA = uid('meta');
var id = 0;

var setMetadata = function (it) {
  defineProperty(it, METADATA, { value: {
    objectID: 'O' + id++, // object ID
    weakData: {}          // weak collections IDs
  } });
};

var fastKey = function (it, create) {
  // return a primitive with prefix
  if (!isObject(it)) return typeof it == 'symbol' ? it : (typeof it == 'string' ? 'S' : 'P') + it;
  if (!hasOwn(it, METADATA)) {
    // can't set metadata to uncaught frozen object
    if (!isExtensible(it)) return 'F';
    // not necessary to add metadata
    if (!create) return 'E';
    // add missing metadata
    setMetadata(it);
  // return object ID
  } return it[METADATA].objectID;
};

var getWeakData = function (it, create) {
  if (!hasOwn(it, METADATA)) {
    // can't set metadata to uncaught frozen object
    if (!isExtensible(it)) return true;
    // not necessary to add metadata
    if (!create) return false;
    // add missing metadata
    setMetadata(it);
  // return the store of weak collections IDs
  } return it[METADATA].weakData;
};

// add metadata on freeze-family methods calling
var onFreeze = function (it) {
  if (FREEZING && REQUIRED && isExtensible(it) && !hasOwn(it, METADATA)) setMetadata(it);
  return it;
};

var enable = function () {
  meta.enable = function () { /* empty */ };
  REQUIRED = true;
  var getOwnPropertyNames = getOwnPropertyNamesModule.f;
  var splice = uncurryThis([].splice);
  var test = {};
  test[METADATA] = 1;

  // prevent exposing of metadata key
  if (getOwnPropertyNames(test).length) {
    getOwnPropertyNamesModule.f = function (it) {
      var result = getOwnPropertyNames(it);
      for (var i = 0, length = result.length; i < length; i++) {
        if (result[i] === METADATA) {
          splice(result, i, 1);
          break;
        }
      } return result;
    };

    $({ target: 'Object', stat: true, forced: true }, {
      getOwnPropertyNames: getOwnPropertyNamesExternalModule.f
    });
  }
};

var meta = module.exports = {
  enable: enable,
  fastKey: fastKey,
  getWeakData: getWeakData,
  onFreeze: onFreeze
};

hiddenKeys[METADATA] = true;


/***/ }),

/***/ 1181:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var NATIVE_WEAK_MAP = __webpack_require__(8622);
var global = __webpack_require__(4475);
var isObject = __webpack_require__(34);
var createNonEnumerableProperty = __webpack_require__(6699);
var hasOwn = __webpack_require__(9297);
var shared = __webpack_require__(7629);
var sharedKey = __webpack_require__(6119);
var hiddenKeys = __webpack_require__(421);

var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
var TypeError = global.TypeError;
var WeakMap = global.WeakMap;
var set, get, has;

var enforce = function (it) {
  return has(it) ? get(it) : set(it, {});
};

var getterFor = function (TYPE) {
  return function (it) {
    var state;
    if (!isObject(it) || (state = get(it)).type !== TYPE) {
      throw new TypeError('Incompatible receiver, ' + TYPE + ' required');
    } return state;
  };
};

if (NATIVE_WEAK_MAP || shared.state) {
  var store = shared.state || (shared.state = new WeakMap());
  /* eslint-disable no-self-assign -- prototype methods protection */
  store.get = store.get;
  store.has = store.has;
  store.set = store.set;
  /* eslint-enable no-self-assign -- prototype methods protection */
  set = function (it, metadata) {
    if (store.has(it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);
    metadata.facade = it;
    store.set(it, metadata);
    return metadata;
  };
  get = function (it) {
    return store.get(it) || {};
  };
  has = function (it) {
    return store.has(it);
  };
} else {
  var STATE = sharedKey('state');
  hiddenKeys[STATE] = true;
  set = function (it, metadata) {
    if (hasOwn(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);
    metadata.facade = it;
    createNonEnumerableProperty(it, STATE, metadata);
    return metadata;
  };
  get = function (it) {
    return hasOwn(it, STATE) ? it[STATE] : {};
  };
  has = function (it) {
    return hasOwn(it, STATE);
  };
}

module.exports = {
  set: set,
  get: get,
  has: has,
  enforce: enforce,
  getterFor: getterFor
};


/***/ }),

/***/ 4209:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var wellKnownSymbol = __webpack_require__(8227);
var Iterators = __webpack_require__(6269);

var ITERATOR = wellKnownSymbol('iterator');
var ArrayPrototype = Array.prototype;

// check on default Array iterator
module.exports = function (it) {
  return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it);
};


/***/ }),

/***/ 4376:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var classof = __webpack_require__(4576);

// `IsArray` abstract operation
// https://tc39.es/ecma262/#sec-isarray
// eslint-disable-next-line es/no-array-isarray -- safe
module.exports = Array.isArray || function isArray(argument) {
  return classof(argument) === 'Array';
};


/***/ }),

/***/ 1108:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var classof = __webpack_require__(6955);

module.exports = function (it) {
  var klass = classof(it);
  return klass === 'BigInt64Array' || klass === 'BigUint64Array';
};


/***/ }),

/***/ 4901:
/***/ (function(module) {


// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
var documentAll = typeof document == 'object' && document.all;

// `IsCallable` abstract operation
// https://tc39.es/ecma262/#sec-iscallable
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
module.exports = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
  return typeof argument == 'function' || argument === documentAll;
} : function (argument) {
  return typeof argument == 'function';
};


/***/ }),

/***/ 3517:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var fails = __webpack_require__(9039);
var isCallable = __webpack_require__(4901);
var classof = __webpack_require__(6955);
var getBuiltIn = __webpack_require__(7751);
var inspectSource = __webpack_require__(3706);

var noop = function () { /* empty */ };
var construct = getBuiltIn('Reflect', 'construct');
var constructorRegExp = /^\s*(?:class|function)\b/;
var exec = uncurryThis(constructorRegExp.exec);
var INCORRECT_TO_STRING = !constructorRegExp.test(noop);

var isConstructorModern = function isConstructor(argument) {
  if (!isCallable(argument)) return false;
  try {
    construct(noop, [], argument);
    return true;
  } catch (error) {
    return false;
  }
};

var isConstructorLegacy = function isConstructor(argument) {
  if (!isCallable(argument)) return false;
  switch (classof(argument)) {
    case 'AsyncFunction':
    case 'GeneratorFunction':
    case 'AsyncGeneratorFunction': return false;
  }
  try {
    // we can't check .prototype since constructors produced by .bind haven't it
    // `Function#toString` throws on some built-it function in some legacy engines
    // (for example, `DOMQuad` and similar in FF41-)
    return INCORRECT_TO_STRING || !!exec(constructorRegExp, inspectSource(argument));
  } catch (error) {
    return true;
  }
};

isConstructorLegacy.sham = true;

// `IsConstructor` abstract operation
// https://tc39.es/ecma262/#sec-isconstructor
module.exports = !construct || fails(function () {
  var called;
  return isConstructorModern(isConstructorModern.call)
    || !isConstructorModern(Object)
    || !isConstructorModern(function () { called = true; })
    || called;
}) ? isConstructorLegacy : isConstructorModern;


/***/ }),

/***/ 6575:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var hasOwn = __webpack_require__(9297);

module.exports = function (descriptor) {
  return descriptor !== undefined && (hasOwn(descriptor, 'value') || hasOwn(descriptor, 'writable'));
};


/***/ }),

/***/ 2796:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var isCallable = __webpack_require__(4901);

var replacement = /#|\.prototype\./;

var isForced = function (feature, detection) {
  var value = data[normalize(feature)];
  return value === POLYFILL ? true
    : value === NATIVE ? false
    : isCallable(detection) ? fails(detection)
    : !!detection;
};

var normalize = isForced.normalize = function (string) {
  return String(string).replace(replacement, '.').toLowerCase();
};

var data = isForced.data = {};
var NATIVE = isForced.NATIVE = 'N';
var POLYFILL = isForced.POLYFILL = 'P';

module.exports = isForced;


/***/ }),

/***/ 2087:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isObject = __webpack_require__(34);

var floor = Math.floor;

// `IsIntegralNumber` abstract operation
// https://tc39.es/ecma262/#sec-isintegralnumber
// eslint-disable-next-line es/no-number-isinteger -- safe
module.exports = Number.isInteger || function isInteger(it) {
  return !isObject(it) && isFinite(it) && floor(it) === it;
};


/***/ }),

/***/ 4117:
/***/ (function(module) {


// we can't use just `it == null` since of `document.all` special case
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
module.exports = function (it) {
  return it === null || it === undefined;
};


/***/ }),

/***/ 34:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isCallable = __webpack_require__(4901);

module.exports = function (it) {
  return typeof it == 'object' ? it !== null : isCallable(it);
};


/***/ }),

/***/ 3925:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isObject = __webpack_require__(34);

module.exports = function (argument) {
  return isObject(argument) || argument === null;
};


/***/ }),

/***/ 6395:
/***/ (function(module) {


module.exports = false;


/***/ }),

/***/ 788:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isObject = __webpack_require__(34);
var classof = __webpack_require__(4576);
var wellKnownSymbol = __webpack_require__(8227);

var MATCH = wellKnownSymbol('match');

// `IsRegExp` abstract operation
// https://tc39.es/ecma262/#sec-isregexp
module.exports = function (it) {
  var isRegExp;
  return isObject(it) && ((isRegExp = it[MATCH]) !== undefined ? !!isRegExp : classof(it) === 'RegExp');
};


/***/ }),

/***/ 757:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var getBuiltIn = __webpack_require__(7751);
var isCallable = __webpack_require__(4901);
var isPrototypeOf = __webpack_require__(1625);
var USE_SYMBOL_AS_UID = __webpack_require__(7040);

var $Object = Object;

module.exports = USE_SYMBOL_AS_UID ? function (it) {
  return typeof it == 'symbol';
} : function (it) {
  var $Symbol = getBuiltIn('Symbol');
  return isCallable($Symbol) && isPrototypeOf($Symbol.prototype, $Object(it));
};


/***/ }),

/***/ 2652:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var bind = __webpack_require__(6080);
var call = __webpack_require__(9565);
var anObject = __webpack_require__(8551);
var tryToString = __webpack_require__(6823);
var isArrayIteratorMethod = __webpack_require__(4209);
var lengthOfArrayLike = __webpack_require__(6198);
var isPrototypeOf = __webpack_require__(1625);
var getIterator = __webpack_require__(81);
var getIteratorMethod = __webpack_require__(851);
var iteratorClose = __webpack_require__(9539);

var $TypeError = TypeError;

var Result = function (stopped, result) {
  this.stopped = stopped;
  this.result = result;
};

var ResultPrototype = Result.prototype;

module.exports = function (iterable, unboundFunction, options) {
  var that = options && options.that;
  var AS_ENTRIES = !!(options && options.AS_ENTRIES);
  var IS_RECORD = !!(options && options.IS_RECORD);
  var IS_ITERATOR = !!(options && options.IS_ITERATOR);
  var INTERRUPTED = !!(options && options.INTERRUPTED);
  var fn = bind(unboundFunction, that);
  var iterator, iterFn, index, length, result, next, step;

  var stop = function (condition) {
    if (iterator) iteratorClose(iterator, 'normal', condition);
    return new Result(true, condition);
  };

  var callFn = function (value) {
    if (AS_ENTRIES) {
      anObject(value);
      return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
    } return INTERRUPTED ? fn(value, stop) : fn(value);
  };

  if (IS_RECORD) {
    iterator = iterable.iterator;
  } else if (IS_ITERATOR) {
    iterator = iterable;
  } else {
    iterFn = getIteratorMethod(iterable);
    if (!iterFn) throw new $TypeError(tryToString(iterable) + ' is not iterable');
    // optimisation for array iterators
    if (isArrayIteratorMethod(iterFn)) {
      for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {
        result = callFn(iterable[index]);
        if (result && isPrototypeOf(ResultPrototype, result)) return result;
      } return new Result(false);
    }
    iterator = getIterator(iterable, iterFn);
  }

  next = IS_RECORD ? iterable.next : iterator.next;
  while (!(step = call(next, iterator)).done) {
    try {
      result = callFn(step.value);
    } catch (error) {
      iteratorClose(iterator, 'throw', error);
    }
    if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;
  } return new Result(false);
};


/***/ }),

/***/ 9539:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var call = __webpack_require__(9565);
var anObject = __webpack_require__(8551);
var getMethod = __webpack_require__(5966);

module.exports = function (iterator, kind, value) {
  var innerResult, innerError;
  anObject(iterator);
  try {
    innerResult = getMethod(iterator, 'return');
    if (!innerResult) {
      if (kind === 'throw') throw value;
      return value;
    }
    innerResult = call(innerResult, iterator);
  } catch (error) {
    innerError = true;
    innerResult = error;
  }
  if (kind === 'throw') throw value;
  if (innerError) throw innerResult;
  anObject(innerResult);
  return value;
};


/***/ }),

/***/ 3994:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var IteratorPrototype = (__webpack_require__(7657).IteratorPrototype);
var create = __webpack_require__(2360);
var createPropertyDescriptor = __webpack_require__(6980);
var setToStringTag = __webpack_require__(687);
var Iterators = __webpack_require__(6269);

var returnThis = function () { return this; };

module.exports = function (IteratorConstructor, NAME, next, ENUMERABLE_NEXT) {
  var TO_STRING_TAG = NAME + ' Iterator';
  IteratorConstructor.prototype = create(IteratorPrototype, { next: createPropertyDescriptor(+!ENUMERABLE_NEXT, next) });
  setToStringTag(IteratorConstructor, TO_STRING_TAG, false, true);
  Iterators[TO_STRING_TAG] = returnThis;
  return IteratorConstructor;
};


/***/ }),

/***/ 1088:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var call = __webpack_require__(9565);
var IS_PURE = __webpack_require__(6395);
var FunctionName = __webpack_require__(350);
var isCallable = __webpack_require__(4901);
var createIteratorConstructor = __webpack_require__(3994);
var getPrototypeOf = __webpack_require__(2787);
var setPrototypeOf = __webpack_require__(2967);
var setToStringTag = __webpack_require__(687);
var createNonEnumerableProperty = __webpack_require__(6699);
var defineBuiltIn = __webpack_require__(6840);
var wellKnownSymbol = __webpack_require__(8227);
var Iterators = __webpack_require__(6269);
var IteratorsCore = __webpack_require__(7657);

var PROPER_FUNCTION_NAME = FunctionName.PROPER;
var CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;
var IteratorPrototype = IteratorsCore.IteratorPrototype;
var BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;
var ITERATOR = wellKnownSymbol('iterator');
var KEYS = 'keys';
var VALUES = 'values';
var ENTRIES = 'entries';

var returnThis = function () { return this; };

module.exports = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {
  createIteratorConstructor(IteratorConstructor, NAME, next);

  var getIterationMethod = function (KIND) {
    if (KIND === DEFAULT && defaultIterator) return defaultIterator;
    if (!BUGGY_SAFARI_ITERATORS && KIND && KIND in IterablePrototype) return IterablePrototype[KIND];

    switch (KIND) {
      case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };
      case VALUES: return function values() { return new IteratorConstructor(this, KIND); };
      case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };
    }

    return function () { return new IteratorConstructor(this); };
  };

  var TO_STRING_TAG = NAME + ' Iterator';
  var INCORRECT_VALUES_NAME = false;
  var IterablePrototype = Iterable.prototype;
  var nativeIterator = IterablePrototype[ITERATOR]
    || IterablePrototype['@@iterator']
    || DEFAULT && IterablePrototype[DEFAULT];
  var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);
  var anyNativeIterator = NAME === 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;
  var CurrentIteratorPrototype, methods, KEY;

  // fix native
  if (anyNativeIterator) {
    CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));
    if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {
      if (!IS_PURE && getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {
        if (setPrototypeOf) {
          setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);
        } else if (!isCallable(CurrentIteratorPrototype[ITERATOR])) {
          defineBuiltIn(CurrentIteratorPrototype, ITERATOR, returnThis);
        }
      }
      // Set @@toStringTag to native iterators
      setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true, true);
      if (IS_PURE) Iterators[TO_STRING_TAG] = returnThis;
    }
  }

  // fix Array.prototype.{ values, @@iterator }.name in V8 / FF
  if (PROPER_FUNCTION_NAME && DEFAULT === VALUES && nativeIterator && nativeIterator.name !== VALUES) {
    if (!IS_PURE && CONFIGURABLE_FUNCTION_NAME) {
      createNonEnumerableProperty(IterablePrototype, 'name', VALUES);
    } else {
      INCORRECT_VALUES_NAME = true;
      defaultIterator = function values() { return call(nativeIterator, this); };
    }
  }

  // export additional methods
  if (DEFAULT) {
    methods = {
      values: getIterationMethod(VALUES),
      keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),
      entries: getIterationMethod(ENTRIES)
    };
    if (FORCED) for (KEY in methods) {
      if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {
        defineBuiltIn(IterablePrototype, KEY, methods[KEY]);
      }
    } else $({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);
  }

  // define iterator
  if ((!IS_PURE || FORCED) && IterablePrototype[ITERATOR] !== defaultIterator) {
    defineBuiltIn(IterablePrototype, ITERATOR, defaultIterator, { name: DEFAULT });
  }
  Iterators[NAME] = defaultIterator;

  return methods;
};


/***/ }),

/***/ 7657:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var isCallable = __webpack_require__(4901);
var isObject = __webpack_require__(34);
var create = __webpack_require__(2360);
var getPrototypeOf = __webpack_require__(2787);
var defineBuiltIn = __webpack_require__(6840);
var wellKnownSymbol = __webpack_require__(8227);
var IS_PURE = __webpack_require__(6395);

var ITERATOR = wellKnownSymbol('iterator');
var BUGGY_SAFARI_ITERATORS = false;

// `%IteratorPrototype%` object
// https://tc39.es/ecma262/#sec-%iteratorprototype%-object
var IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;

/* eslint-disable es/no-array-prototype-keys -- safe */
if ([].keys) {
  arrayIterator = [].keys();
  // Safari 8 has buggy iterators w/o `next`
  if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;
  else {
    PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));
    if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;
  }
}

var NEW_ITERATOR_PROTOTYPE = !isObject(IteratorPrototype) || fails(function () {
  var test = {};
  // FF44- legacy iterators case
  return IteratorPrototype[ITERATOR].call(test) !== test;
});

if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {};
else if (IS_PURE) IteratorPrototype = create(IteratorPrototype);

// `%IteratorPrototype%[@@iterator]()` method
// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
if (!isCallable(IteratorPrototype[ITERATOR])) {
  defineBuiltIn(IteratorPrototype, ITERATOR, function () {
    return this;
  });
}

module.exports = {
  IteratorPrototype: IteratorPrototype,
  BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS
};


/***/ }),

/***/ 6269:
/***/ (function(module) {


module.exports = {};


/***/ }),

/***/ 6198:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toLength = __webpack_require__(8014);

// `LengthOfArrayLike` abstract operation
// https://tc39.es/ecma262/#sec-lengthofarraylike
module.exports = function (obj) {
  return toLength(obj.length);
};


/***/ }),

/***/ 283:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var fails = __webpack_require__(9039);
var isCallable = __webpack_require__(4901);
var hasOwn = __webpack_require__(9297);
var DESCRIPTORS = __webpack_require__(3724);
var CONFIGURABLE_FUNCTION_NAME = (__webpack_require__(350).CONFIGURABLE);
var inspectSource = __webpack_require__(3706);
var InternalStateModule = __webpack_require__(1181);

var enforceInternalState = InternalStateModule.enforce;
var getInternalState = InternalStateModule.get;
var $String = String;
// eslint-disable-next-line es/no-object-defineproperty -- safe
var defineProperty = Object.defineProperty;
var stringSlice = uncurryThis(''.slice);
var replace = uncurryThis(''.replace);
var join = uncurryThis([].join);

var CONFIGURABLE_LENGTH = DESCRIPTORS && !fails(function () {
  return defineProperty(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
});

var TEMPLATE = String(String).split('String');

var makeBuiltIn = module.exports = function (value, name, options) {
  if (stringSlice($String(name), 0, 7) === 'Symbol(') {
    name = '[' + replace($String(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
  }
  if (options && options.getter) name = 'get ' + name;
  if (options && options.setter) name = 'set ' + name;
  if (!hasOwn(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {
    if (DESCRIPTORS) defineProperty(value, 'name', { value: name, configurable: true });
    else value.name = name;
  }
  if (CONFIGURABLE_LENGTH && options && hasOwn(options, 'arity') && value.length !== options.arity) {
    defineProperty(value, 'length', { value: options.arity });
  }
  try {
    if (options && hasOwn(options, 'constructor') && options.constructor) {
      if (DESCRIPTORS) defineProperty(value, 'prototype', { writable: false });
    // in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
    } else if (value.prototype) value.prototype = undefined;
  } catch (error) { /* empty */ }
  var state = enforceInternalState(value);
  if (!hasOwn(state, 'source')) {
    state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
  } return value;
};

// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
// eslint-disable-next-line no-extend-native -- required
Function.prototype.toString = makeBuiltIn(function toString() {
  return isCallable(this) && getInternalState(this).source || inspectSource(this);
}, 'toString');


/***/ }),

/***/ 3164:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var sign = __webpack_require__(7782);

var abs = Math.abs;

var EPSILON = 2.220446049250313e-16; // Number.EPSILON
var INVERSE_EPSILON = 1 / EPSILON;

var roundTiesToEven = function (n) {
  return n + INVERSE_EPSILON - INVERSE_EPSILON;
};

module.exports = function (x, FLOAT_EPSILON, FLOAT_MAX_VALUE, FLOAT_MIN_VALUE) {
  var n = +x;
  var absolute = abs(n);
  var s = sign(n);
  if (absolute < FLOAT_MIN_VALUE) return s * roundTiesToEven(absolute / FLOAT_MIN_VALUE / FLOAT_EPSILON) * FLOAT_MIN_VALUE * FLOAT_EPSILON;
  var a = (1 + FLOAT_EPSILON / EPSILON) * absolute;
  var result = a - (a - absolute);
  // eslint-disable-next-line no-self-compare -- NaN check
  if (result > FLOAT_MAX_VALUE || result !== result) return s * Infinity;
  return s * result;
};


/***/ }),

/***/ 5617:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var floatRound = __webpack_require__(3164);

var FLOAT32_EPSILON = 1.1920928955078125e-7; // 2 ** -23;
var FLOAT32_MAX_VALUE = 3.4028234663852886e+38; // 2 ** 128 - 2 ** 104
var FLOAT32_MIN_VALUE = 1.1754943508222875e-38; // 2 ** -126;

// `Math.fround` method implementation
// https://tc39.es/ecma262/#sec-math.fround
// eslint-disable-next-line es/no-math-fround -- safe
module.exports = Math.fround || function fround(x) {
  return floatRound(x, FLOAT32_EPSILON, FLOAT32_MAX_VALUE, FLOAT32_MIN_VALUE);
};


/***/ }),

/***/ 7782:
/***/ (function(module) {


// `Math.sign` method implementation
// https://tc39.es/ecma262/#sec-math.sign
// eslint-disable-next-line es/no-math-sign -- safe
module.exports = Math.sign || function sign(x) {
  var n = +x;
  // eslint-disable-next-line no-self-compare -- NaN check
  return n === 0 || n !== n ? n : n < 0 ? -1 : 1;
};


/***/ }),

/***/ 741:
/***/ (function(module) {


var ceil = Math.ceil;
var floor = Math.floor;

// `Math.trunc` method
// https://tc39.es/ecma262/#sec-math.trunc
// eslint-disable-next-line es/no-math-trunc -- safe
module.exports = Math.trunc || function trunc(x) {
  var n = +x;
  return (n > 0 ? floor : ceil)(n);
};


/***/ }),

/***/ 1955:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var safeGetBuiltIn = __webpack_require__(3389);
var bind = __webpack_require__(6080);
var macrotask = (__webpack_require__(9225).set);
var Queue = __webpack_require__(8265);
var IS_IOS = __webpack_require__(8119);
var IS_IOS_PEBBLE = __webpack_require__(28);
var IS_WEBOS_WEBKIT = __webpack_require__(6765);
var IS_NODE = __webpack_require__(9088);

var MutationObserver = global.MutationObserver || global.WebKitMutationObserver;
var document = global.document;
var process = global.process;
var Promise = global.Promise;
var microtask = safeGetBuiltIn('queueMicrotask');
var notify, toggle, node, promise, then;

// modern engines have queueMicrotask method
if (!microtask) {
  var queue = new Queue();

  var flush = function () {
    var parent, fn;
    if (IS_NODE && (parent = process.domain)) parent.exit();
    while (fn = queue.get()) try {
      fn();
    } catch (error) {
      if (queue.head) notify();
      throw error;
    }
    if (parent) parent.enter();
  };

  // browsers with MutationObserver, except iOS - https://github.com/zloirock/core-js/issues/339
  // also except WebOS Webkit https://github.com/zloirock/core-js/issues/898
  if (!IS_IOS && !IS_NODE && !IS_WEBOS_WEBKIT && MutationObserver && document) {
    toggle = true;
    node = document.createTextNode('');
    new MutationObserver(flush).observe(node, { characterData: true });
    notify = function () {
      node.data = toggle = !toggle;
    };
  // environments with maybe non-completely correct, but existent Promise
  } else if (!IS_IOS_PEBBLE && Promise && Promise.resolve) {
    // Promise.resolve without an argument throws an error in LG WebOS 2
    promise = Promise.resolve(undefined);
    // workaround of WebKit ~ iOS Safari 10.1 bug
    promise.constructor = Promise;
    then = bind(promise.then, promise);
    notify = function () {
      then(flush);
    };
  // Node.js without promises
  } else if (IS_NODE) {
    notify = function () {
      process.nextTick(flush);
    };
  // for other environments - macrotask based on:
  // - setImmediate
  // - MessageChannel
  // - window.postMessage
  // - onreadystatechange
  // - setTimeout
  } else {
    // `webpack` dev server bug on IE global methods - use bind(fn, global)
    macrotask = bind(macrotask, global);
    notify = function () {
      macrotask(flush);
    };
  }

  microtask = function (fn) {
    if (!queue.head) notify();
    queue.add(fn);
  };
}

module.exports = microtask;


/***/ }),

/***/ 6043:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var aCallable = __webpack_require__(9306);

var $TypeError = TypeError;

var PromiseCapability = function (C) {
  var resolve, reject;
  this.promise = new C(function ($$resolve, $$reject) {
    if (resolve !== undefined || reject !== undefined) throw new $TypeError('Bad Promise constructor');
    resolve = $$resolve;
    reject = $$reject;
  });
  this.resolve = aCallable(resolve);
  this.reject = aCallable(reject);
};

// `NewPromiseCapability` abstract operation
// https://tc39.es/ecma262/#sec-newpromisecapability
module.exports.f = function (C) {
  return new PromiseCapability(C);
};


/***/ }),

/***/ 2603:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toString = __webpack_require__(655);

module.exports = function (argument, $default) {
  return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument);
};


/***/ }),

/***/ 5749:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isRegExp = __webpack_require__(788);

var $TypeError = TypeError;

module.exports = function (it) {
  if (isRegExp(it)) {
    throw new $TypeError("The method doesn't accept regular expressions");
  } return it;
};


/***/ }),

/***/ 4213:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var uncurryThis = __webpack_require__(9504);
var call = __webpack_require__(9565);
var fails = __webpack_require__(9039);
var objectKeys = __webpack_require__(1072);
var getOwnPropertySymbolsModule = __webpack_require__(3717);
var propertyIsEnumerableModule = __webpack_require__(8773);
var toObject = __webpack_require__(8981);
var IndexedObject = __webpack_require__(7055);

// eslint-disable-next-line es/no-object-assign -- safe
var $assign = Object.assign;
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
var defineProperty = Object.defineProperty;
var concat = uncurryThis([].concat);

// `Object.assign` method
// https://tc39.es/ecma262/#sec-object.assign
module.exports = !$assign || fails(function () {
  // should have correct order of operations (Edge bug)
  if (DESCRIPTORS && $assign({ b: 1 }, $assign(defineProperty({}, 'a', {
    enumerable: true,
    get: function () {
      defineProperty(this, 'b', {
        value: 3,
        enumerable: false
      });
    }
  }), { b: 2 })).b !== 1) return true;
  // should work with symbols and should have deterministic property order (V8 bug)
  var A = {};
  var B = {};
  // eslint-disable-next-line es/no-symbol -- safe
  var symbol = Symbol('assign detection');
  var alphabet = 'abcdefghijklmnopqrst';
  A[symbol] = 7;
  alphabet.split('').forEach(function (chr) { B[chr] = chr; });
  return $assign({}, A)[symbol] !== 7 || objectKeys($assign({}, B)).join('') !== alphabet;
}) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`
  var T = toObject(target);
  var argumentsLength = arguments.length;
  var index = 1;
  var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
  var propertyIsEnumerable = propertyIsEnumerableModule.f;
  while (argumentsLength > index) {
    var S = IndexedObject(arguments[index++]);
    var keys = getOwnPropertySymbols ? concat(objectKeys(S), getOwnPropertySymbols(S)) : objectKeys(S);
    var length = keys.length;
    var j = 0;
    var key;
    while (length > j) {
      key = keys[j++];
      if (!DESCRIPTORS || call(propertyIsEnumerable, S, key)) T[key] = S[key];
    }
  } return T;
} : $assign;


/***/ }),

/***/ 2360:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


/* global ActiveXObject -- old IE, WSH */
var anObject = __webpack_require__(8551);
var definePropertiesModule = __webpack_require__(6801);
var enumBugKeys = __webpack_require__(8727);
var hiddenKeys = __webpack_require__(421);
var html = __webpack_require__(397);
var documentCreateElement = __webpack_require__(4055);
var sharedKey = __webpack_require__(6119);

var GT = '>';
var LT = '<';
var PROTOTYPE = 'prototype';
var SCRIPT = 'script';
var IE_PROTO = sharedKey('IE_PROTO');

var EmptyConstructor = function () { /* empty */ };

var scriptTag = function (content) {
  return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
};

// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
var NullProtoObjectViaActiveX = function (activeXDocument) {
  activeXDocument.write(scriptTag(''));
  activeXDocument.close();
  var temp = activeXDocument.parentWindow.Object;
  activeXDocument = null; // avoid memory leak
  return temp;
};

// Create object with fake `null` prototype: use iframe Object with cleared prototype
var NullProtoObjectViaIFrame = function () {
  // Thrash, waste and sodomy: IE GC bug
  var iframe = documentCreateElement('iframe');
  var JS = 'java' + SCRIPT + ':';
  var iframeDocument;
  iframe.style.display = 'none';
  html.appendChild(iframe);
  // https://github.com/zloirock/core-js/issues/475
  iframe.src = String(JS);
  iframeDocument = iframe.contentWindow.document;
  iframeDocument.open();
  iframeDocument.write(scriptTag('document.F=Object'));
  iframeDocument.close();
  return iframeDocument.F;
};

// Check for document.domain and active x support
// No need to use active x approach when document.domain is not set
// see https://github.com/es-shims/es5-shim/issues/150
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
// avoid IE GC bug
var activeXDocument;
var NullProtoObject = function () {
  try {
    activeXDocument = new ActiveXObject('htmlfile');
  } catch (error) { /* ignore */ }
  NullProtoObject = typeof document != 'undefined'
    ? document.domain && activeXDocument
      ? NullProtoObjectViaActiveX(activeXDocument) // old IE
      : NullProtoObjectViaIFrame()
    : NullProtoObjectViaActiveX(activeXDocument); // WSH
  var length = enumBugKeys.length;
  while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
  return NullProtoObject();
};

hiddenKeys[IE_PROTO] = true;

// `Object.create` method
// https://tc39.es/ecma262/#sec-object.create
// eslint-disable-next-line es/no-object-create -- safe
module.exports = Object.create || function create(O, Properties) {
  var result;
  if (O !== null) {
    EmptyConstructor[PROTOTYPE] = anObject(O);
    result = new EmptyConstructor();
    EmptyConstructor[PROTOTYPE] = null;
    // add "__proto__" for Object.getPrototypeOf polyfill
    result[IE_PROTO] = O;
  } else result = NullProtoObject();
  return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
};


/***/ }),

/***/ 6801:
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var V8_PROTOTYPE_DEFINE_BUG = __webpack_require__(8686);
var definePropertyModule = __webpack_require__(4913);
var anObject = __webpack_require__(8551);
var toIndexedObject = __webpack_require__(5397);
var objectKeys = __webpack_require__(1072);

// `Object.defineProperties` method
// https://tc39.es/ecma262/#sec-object.defineproperties
// eslint-disable-next-line es/no-object-defineproperties -- safe
exports.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
  anObject(O);
  var props = toIndexedObject(Properties);
  var keys = objectKeys(Properties);
  var length = keys.length;
  var index = 0;
  var key;
  while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);
  return O;
};


/***/ }),

/***/ 4913:
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var IE8_DOM_DEFINE = __webpack_require__(5917);
var V8_PROTOTYPE_DEFINE_BUG = __webpack_require__(8686);
var anObject = __webpack_require__(8551);
var toPropertyKey = __webpack_require__(6969);

var $TypeError = TypeError;
// eslint-disable-next-line es/no-object-defineproperty -- safe
var $defineProperty = Object.defineProperty;
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
var ENUMERABLE = 'enumerable';
var CONFIGURABLE = 'configurable';
var WRITABLE = 'writable';

// `Object.defineProperty` method
// https://tc39.es/ecma262/#sec-object.defineproperty
exports.f = DESCRIPTORS ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) {
  anObject(O);
  P = toPropertyKey(P);
  anObject(Attributes);
  if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
    var current = $getOwnPropertyDescriptor(O, P);
    if (current && current[WRITABLE]) {
      O[P] = Attributes.value;
      Attributes = {
        configurable: CONFIGURABLE in Attributes ? Attributes[CONFIGURABLE] : current[CONFIGURABLE],
        enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],
        writable: false
      };
    }
  } return $defineProperty(O, P, Attributes);
} : $defineProperty : function defineProperty(O, P, Attributes) {
  anObject(O);
  P = toPropertyKey(P);
  anObject(Attributes);
  if (IE8_DOM_DEFINE) try {
    return $defineProperty(O, P, Attributes);
  } catch (error) { /* empty */ }
  if ('get' in Attributes || 'set' in Attributes) throw new $TypeError('Accessors not supported');
  if ('value' in Attributes) O[P] = Attributes.value;
  return O;
};


/***/ }),

/***/ 7347:
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var call = __webpack_require__(9565);
var propertyIsEnumerableModule = __webpack_require__(8773);
var createPropertyDescriptor = __webpack_require__(6980);
var toIndexedObject = __webpack_require__(5397);
var toPropertyKey = __webpack_require__(6969);
var hasOwn = __webpack_require__(9297);
var IE8_DOM_DEFINE = __webpack_require__(5917);

// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;

// `Object.getOwnPropertyDescriptor` method
// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
exports.f = DESCRIPTORS ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
  O = toIndexedObject(O);
  P = toPropertyKey(P);
  if (IE8_DOM_DEFINE) try {
    return $getOwnPropertyDescriptor(O, P);
  } catch (error) { /* empty */ }
  if (hasOwn(O, P)) return createPropertyDescriptor(!call(propertyIsEnumerableModule.f, O, P), O[P]);
};


/***/ }),

/***/ 298:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable es/no-object-getownpropertynames -- safe */
var classof = __webpack_require__(4576);
var toIndexedObject = __webpack_require__(5397);
var $getOwnPropertyNames = (__webpack_require__(8480).f);
var arraySlice = __webpack_require__(7680);

var windowNames = typeof window == 'object' && window && Object.getOwnPropertyNames
  ? Object.getOwnPropertyNames(window) : [];

var getWindowNames = function (it) {
  try {
    return $getOwnPropertyNames(it);
  } catch (error) {
    return arraySlice(windowNames);
  }
};

// fallback for IE11 buggy Object.getOwnPropertyNames with iframe and window
module.exports.f = function getOwnPropertyNames(it) {
  return windowNames && classof(it) === 'Window'
    ? getWindowNames(it)
    : $getOwnPropertyNames(toIndexedObject(it));
};


/***/ }),

/***/ 8480:
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {


var internalObjectKeys = __webpack_require__(1828);
var enumBugKeys = __webpack_require__(8727);

var hiddenKeys = enumBugKeys.concat('length', 'prototype');

// `Object.getOwnPropertyNames` method
// https://tc39.es/ecma262/#sec-object.getownpropertynames
// eslint-disable-next-line es/no-object-getownpropertynames -- safe
exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
  return internalObjectKeys(O, hiddenKeys);
};


/***/ }),

/***/ 3717:
/***/ (function(__unused_webpack_module, exports) {


// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
exports.f = Object.getOwnPropertySymbols;


/***/ }),

/***/ 2787:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var hasOwn = __webpack_require__(9297);
var isCallable = __webpack_require__(4901);
var toObject = __webpack_require__(8981);
var sharedKey = __webpack_require__(6119);
var CORRECT_PROTOTYPE_GETTER = __webpack_require__(2211);

var IE_PROTO = sharedKey('IE_PROTO');
var $Object = Object;
var ObjectPrototype = $Object.prototype;

// `Object.getPrototypeOf` method
// https://tc39.es/ecma262/#sec-object.getprototypeof
// eslint-disable-next-line es/no-object-getprototypeof -- safe
module.exports = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) {
  var object = toObject(O);
  if (hasOwn(object, IE_PROTO)) return object[IE_PROTO];
  var constructor = object.constructor;
  if (isCallable(constructor) && object instanceof constructor) {
    return constructor.prototype;
  } return object instanceof $Object ? ObjectPrototype : null;
};


/***/ }),

/***/ 4124:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var isObject = __webpack_require__(34);
var classof = __webpack_require__(4576);
var ARRAY_BUFFER_NON_EXTENSIBLE = __webpack_require__(5652);

// eslint-disable-next-line es/no-object-isextensible -- safe
var $isExtensible = Object.isExtensible;
var FAILS_ON_PRIMITIVES = fails(function () { $isExtensible(1); });

// `Object.isExtensible` method
// https://tc39.es/ecma262/#sec-object.isextensible
module.exports = (FAILS_ON_PRIMITIVES || ARRAY_BUFFER_NON_EXTENSIBLE) ? function isExtensible(it) {
  if (!isObject(it)) return false;
  if (ARRAY_BUFFER_NON_EXTENSIBLE && classof(it) === 'ArrayBuffer') return false;
  return $isExtensible ? $isExtensible(it) : true;
} : $isExtensible;


/***/ }),

/***/ 1625:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);

module.exports = uncurryThis({}.isPrototypeOf);


/***/ }),

/***/ 1828:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var hasOwn = __webpack_require__(9297);
var toIndexedObject = __webpack_require__(5397);
var indexOf = (__webpack_require__(9617).indexOf);
var hiddenKeys = __webpack_require__(421);

var push = uncurryThis([].push);

module.exports = function (object, names) {
  var O = toIndexedObject(object);
  var i = 0;
  var result = [];
  var key;
  for (key in O) !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key);
  // Don't enum bug & hidden keys
  while (names.length > i) if (hasOwn(O, key = names[i++])) {
    ~indexOf(result, key) || push(result, key);
  }
  return result;
};


/***/ }),

/***/ 1072:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var internalObjectKeys = __webpack_require__(1828);
var enumBugKeys = __webpack_require__(8727);

// `Object.keys` method
// https://tc39.es/ecma262/#sec-object.keys
// eslint-disable-next-line es/no-object-keys -- safe
module.exports = Object.keys || function keys(O) {
  return internalObjectKeys(O, enumBugKeys);
};


/***/ }),

/***/ 8773:
/***/ (function(__unused_webpack_module, exports) {


var $propertyIsEnumerable = {}.propertyIsEnumerable;
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;

// Nashorn ~ JDK8 bug
var NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({ 1: 2 }, 1);

// `Object.prototype.propertyIsEnumerable` method implementation
// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
exports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
  var descriptor = getOwnPropertyDescriptor(this, V);
  return !!descriptor && descriptor.enumerable;
} : $propertyIsEnumerable;


/***/ }),

/***/ 2967:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable no-proto -- safe */
var uncurryThisAccessor = __webpack_require__(6706);
var anObject = __webpack_require__(8551);
var aPossiblePrototype = __webpack_require__(3506);

// `Object.setPrototypeOf` method
// https://tc39.es/ecma262/#sec-object.setprototypeof
// Works with __proto__ only. Old v8 can't work with null proto objects.
// eslint-disable-next-line es/no-object-setprototypeof -- safe
module.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {
  var CORRECT_SETTER = false;
  var test = {};
  var setter;
  try {
    setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set');
    setter(test, []);
    CORRECT_SETTER = test instanceof Array;
  } catch (error) { /* empty */ }
  return function setPrototypeOf(O, proto) {
    anObject(O);
    aPossiblePrototype(proto);
    if (CORRECT_SETTER) setter(O, proto);
    else O.__proto__ = proto;
    return O;
  };
}() : undefined);


/***/ }),

/***/ 3179:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var TO_STRING_TAG_SUPPORT = __webpack_require__(2140);
var classof = __webpack_require__(6955);

// `Object.prototype.toString` method implementation
// https://tc39.es/ecma262/#sec-object.prototype.tostring
module.exports = TO_STRING_TAG_SUPPORT ? {}.toString : function toString() {
  return '[object ' + classof(this) + ']';
};


/***/ }),

/***/ 4270:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var call = __webpack_require__(9565);
var isCallable = __webpack_require__(4901);
var isObject = __webpack_require__(34);

var $TypeError = TypeError;

// `OrdinaryToPrimitive` abstract operation
// https://tc39.es/ecma262/#sec-ordinarytoprimitive
module.exports = function (input, pref) {
  var fn, val;
  if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;
  if (isCallable(fn = input.valueOf) && !isObject(val = call(fn, input))) return val;
  if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;
  throw new $TypeError("Can't convert object to primitive value");
};


/***/ }),

/***/ 5031:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var getBuiltIn = __webpack_require__(7751);
var uncurryThis = __webpack_require__(9504);
var getOwnPropertyNamesModule = __webpack_require__(8480);
var getOwnPropertySymbolsModule = __webpack_require__(3717);
var anObject = __webpack_require__(8551);

var concat = uncurryThis([].concat);

// all object keys, includes non-enumerable and symbols
module.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {
  var keys = getOwnPropertyNamesModule.f(anObject(it));
  var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
  return getOwnPropertySymbols ? concat(keys, getOwnPropertySymbols(it)) : keys;
};


/***/ }),

/***/ 9167:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);

module.exports = global;


/***/ }),

/***/ 1103:
/***/ (function(module) {


module.exports = function (exec) {
  try {
    return { error: false, value: exec() };
  } catch (error) {
    return { error: true, value: error };
  }
};


/***/ }),

/***/ 916:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var NativePromiseConstructor = __webpack_require__(550);
var isCallable = __webpack_require__(4901);
var isForced = __webpack_require__(2796);
var inspectSource = __webpack_require__(3706);
var wellKnownSymbol = __webpack_require__(8227);
var IS_BROWSER = __webpack_require__(7290);
var IS_DENO = __webpack_require__(516);
var IS_PURE = __webpack_require__(6395);
var V8_VERSION = __webpack_require__(7388);

var NativePromisePrototype = NativePromiseConstructor && NativePromiseConstructor.prototype;
var SPECIES = wellKnownSymbol('species');
var SUBCLASSING = false;
var NATIVE_PROMISE_REJECTION_EVENT = isCallable(global.PromiseRejectionEvent);

var FORCED_PROMISE_CONSTRUCTOR = isForced('Promise', function () {
  var PROMISE_CONSTRUCTOR_SOURCE = inspectSource(NativePromiseConstructor);
  var GLOBAL_CORE_JS_PROMISE = PROMISE_CONSTRUCTOR_SOURCE !== String(NativePromiseConstructor);
  // V8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables
  // https://bugs.chromium.org/p/chromium/issues/detail?id=830565
  // We can't detect it synchronously, so just check versions
  if (!GLOBAL_CORE_JS_PROMISE && V8_VERSION === 66) return true;
  // We need Promise#{ catch, finally } in the pure version for preventing prototype pollution
  if (IS_PURE && !(NativePromisePrototype['catch'] && NativePromisePrototype['finally'])) return true;
  // We can't use @@species feature detection in V8 since it causes
  // deoptimization and performance degradation
  // https://github.com/zloirock/core-js/issues/679
  if (!V8_VERSION || V8_VERSION < 51 || !/native code/.test(PROMISE_CONSTRUCTOR_SOURCE)) {
    // Detect correctness of subclassing with @@species support
    var promise = new NativePromiseConstructor(function (resolve) { resolve(1); });
    var FakePromise = function (exec) {
      exec(function () { /* empty */ }, function () { /* empty */ });
    };
    var constructor = promise.constructor = {};
    constructor[SPECIES] = FakePromise;
    SUBCLASSING = promise.then(function () { /* empty */ }) instanceof FakePromise;
    if (!SUBCLASSING) return true;
  // Unhandled rejections tracking support, NodeJS Promise without it fails @@species test
  } return !GLOBAL_CORE_JS_PROMISE && (IS_BROWSER || IS_DENO) && !NATIVE_PROMISE_REJECTION_EVENT;
});

module.exports = {
  CONSTRUCTOR: FORCED_PROMISE_CONSTRUCTOR,
  REJECTION_EVENT: NATIVE_PROMISE_REJECTION_EVENT,
  SUBCLASSING: SUBCLASSING
};


/***/ }),

/***/ 550:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);

module.exports = global.Promise;


/***/ }),

/***/ 3438:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var anObject = __webpack_require__(8551);
var isObject = __webpack_require__(34);
var newPromiseCapability = __webpack_require__(6043);

module.exports = function (C, x) {
  anObject(C);
  if (isObject(x) && x.constructor === C) return x;
  var promiseCapability = newPromiseCapability.f(C);
  var resolve = promiseCapability.resolve;
  resolve(x);
  return promiseCapability.promise;
};


/***/ }),

/***/ 537:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var NativePromiseConstructor = __webpack_require__(550);
var checkCorrectnessOfIteration = __webpack_require__(4428);
var FORCED_PROMISE_CONSTRUCTOR = (__webpack_require__(916).CONSTRUCTOR);

module.exports = FORCED_PROMISE_CONSTRUCTOR || !checkCorrectnessOfIteration(function (iterable) {
  NativePromiseConstructor.all(iterable).then(undefined, function () { /* empty */ });
});


/***/ }),

/***/ 1056:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var defineProperty = (__webpack_require__(4913).f);

module.exports = function (Target, Source, key) {
  key in Target || defineProperty(Target, key, {
    configurable: true,
    get: function () { return Source[key]; },
    set: function (it) { Source[key] = it; }
  });
};


/***/ }),

/***/ 8265:
/***/ (function(module) {


var Queue = function () {
  this.head = null;
  this.tail = null;
};

Queue.prototype = {
  add: function (item) {
    var entry = { item: item, next: null };
    var tail = this.tail;
    if (tail) tail.next = entry;
    else this.head = entry;
    this.tail = entry;
  },
  get: function () {
    var entry = this.head;
    if (entry) {
      var next = this.head = entry.next;
      if (next === null) this.tail = null;
      return entry.item;
    }
  }
};

module.exports = Queue;


/***/ }),

/***/ 6682:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var call = __webpack_require__(9565);
var anObject = __webpack_require__(8551);
var isCallable = __webpack_require__(4901);
var classof = __webpack_require__(4576);
var regexpExec = __webpack_require__(7323);

var $TypeError = TypeError;

// `RegExpExec` abstract operation
// https://tc39.es/ecma262/#sec-regexpexec
module.exports = function (R, S) {
  var exec = R.exec;
  if (isCallable(exec)) {
    var result = call(exec, R, S);
    if (result !== null) anObject(result);
    return result;
  }
  if (classof(R) === 'RegExp') return call(regexpExec, R, S);
  throw new $TypeError('RegExp#exec called on incompatible receiver');
};


/***/ }),

/***/ 7323:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable regexp/no-empty-capturing-group, regexp/no-empty-group, regexp/no-lazy-ends -- testing */
/* eslint-disable regexp/no-useless-quantifier -- testing */
var call = __webpack_require__(9565);
var uncurryThis = __webpack_require__(9504);
var toString = __webpack_require__(655);
var regexpFlags = __webpack_require__(7979);
var stickyHelpers = __webpack_require__(8429);
var shared = __webpack_require__(5745);
var create = __webpack_require__(2360);
var getInternalState = (__webpack_require__(1181).get);
var UNSUPPORTED_DOT_ALL = __webpack_require__(3635);
var UNSUPPORTED_NCG = __webpack_require__(8814);

var nativeReplace = shared('native-string-replace', String.prototype.replace);
var nativeExec = RegExp.prototype.exec;
var patchedExec = nativeExec;
var charAt = uncurryThis(''.charAt);
var indexOf = uncurryThis(''.indexOf);
var replace = uncurryThis(''.replace);
var stringSlice = uncurryThis(''.slice);

var UPDATES_LAST_INDEX_WRONG = (function () {
  var re1 = /a/;
  var re2 = /b*/g;
  call(nativeExec, re1, 'a');
  call(nativeExec, re2, 'a');
  return re1.lastIndex !== 0 || re2.lastIndex !== 0;
})();

var UNSUPPORTED_Y = stickyHelpers.BROKEN_CARET;

// nonparticipating capturing group, copied from es5-shim's String#split patch.
var NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;

var PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG;

if (PATCH) {
  patchedExec = function exec(string) {
    var re = this;
    var state = getInternalState(re);
    var str = toString(string);
    var raw = state.raw;
    var result, reCopy, lastIndex, match, i, object, group;

    if (raw) {
      raw.lastIndex = re.lastIndex;
      result = call(patchedExec, raw, str);
      re.lastIndex = raw.lastIndex;
      return result;
    }

    var groups = state.groups;
    var sticky = UNSUPPORTED_Y && re.sticky;
    var flags = call(regexpFlags, re);
    var source = re.source;
    var charsAdded = 0;
    var strCopy = str;

    if (sticky) {
      flags = replace(flags, 'y', '');
      if (indexOf(flags, 'g') === -1) {
        flags += 'g';
      }

      strCopy = stringSlice(str, re.lastIndex);
      // Support anchored sticky behavior.
      if (re.lastIndex > 0 && (!re.multiline || re.multiline && charAt(str, re.lastIndex - 1) !== '\n')) {
        source = '(?: ' + source + ')';
        strCopy = ' ' + strCopy;
        charsAdded++;
      }
      // ^(? + rx + ) is needed, in combination with some str slicing, to
      // simulate the 'y' flag.
      reCopy = new RegExp('^(?:' + source + ')', flags);
    }

    if (NPCG_INCLUDED) {
      reCopy = new RegExp('^' + source + '$(?!\\s)', flags);
    }
    if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;

    match = call(nativeExec, sticky ? reCopy : re, strCopy);

    if (sticky) {
      if (match) {
        match.input = stringSlice(match.input, charsAdded);
        match[0] = stringSlice(match[0], charsAdded);
        match.index = re.lastIndex;
        re.lastIndex += match[0].length;
      } else re.lastIndex = 0;
    } else if (UPDATES_LAST_INDEX_WRONG && match) {
      re.lastIndex = re.global ? match.index + match[0].length : lastIndex;
    }
    if (NPCG_INCLUDED && match && match.length > 1) {
      // Fix browsers whose `exec` methods don't consistently return `undefined`
      // for NPCG, like IE8. NOTE: This doesn't work for /(.?)?/
      call(nativeReplace, match[0], reCopy, function () {
        for (i = 1; i < arguments.length - 2; i++) {
          if (arguments[i] === undefined) match[i] = undefined;
        }
      });
    }

    if (match && groups) {
      match.groups = object = create(null);
      for (i = 0; i < groups.length; i++) {
        group = groups[i];
        object[group[0]] = match[group[1]];
      }
    }

    return match;
  };
}

module.exports = patchedExec;


/***/ }),

/***/ 7979:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var anObject = __webpack_require__(8551);

// `RegExp.prototype.flags` getter implementation
// https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
module.exports = function () {
  var that = anObject(this);
  var result = '';
  if (that.hasIndices) result += 'd';
  if (that.global) result += 'g';
  if (that.ignoreCase) result += 'i';
  if (that.multiline) result += 'm';
  if (that.dotAll) result += 's';
  if (that.unicode) result += 'u';
  if (that.unicodeSets) result += 'v';
  if (that.sticky) result += 'y';
  return result;
};


/***/ }),

/***/ 1034:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var call = __webpack_require__(9565);
var hasOwn = __webpack_require__(9297);
var isPrototypeOf = __webpack_require__(1625);
var regExpFlags = __webpack_require__(7979);

var RegExpPrototype = RegExp.prototype;

module.exports = function (R) {
  var flags = R.flags;
  return flags === undefined && !('flags' in RegExpPrototype) && !hasOwn(R, 'flags') && isPrototypeOf(RegExpPrototype, R)
    ? call(regExpFlags, R) : flags;
};


/***/ }),

/***/ 8429:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var global = __webpack_require__(4475);

// babel-minify and Closure Compiler transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError
var $RegExp = global.RegExp;

var UNSUPPORTED_Y = fails(function () {
  var re = $RegExp('a', 'y');
  re.lastIndex = 2;
  return re.exec('abcd') !== null;
});

// UC Browser bug
// https://github.com/zloirock/core-js/issues/1008
var MISSED_STICKY = UNSUPPORTED_Y || fails(function () {
  return !$RegExp('a', 'y').sticky;
});

var BROKEN_CARET = UNSUPPORTED_Y || fails(function () {
  // https://bugzilla.mozilla.org/show_bug.cgi?id=773687
  var re = $RegExp('^r', 'gy');
  re.lastIndex = 2;
  return re.exec('str') !== null;
});

module.exports = {
  BROKEN_CARET: BROKEN_CARET,
  MISSED_STICKY: MISSED_STICKY,
  UNSUPPORTED_Y: UNSUPPORTED_Y
};


/***/ }),

/***/ 3635:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var global = __webpack_require__(4475);

// babel-minify and Closure Compiler transpiles RegExp('.', 's') -> /./s and it causes SyntaxError
var $RegExp = global.RegExp;

module.exports = fails(function () {
  var re = $RegExp('.', 's');
  return !(re.dotAll && re.test('\n') && re.flags === 's');
});


/***/ }),

/***/ 8814:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var global = __webpack_require__(4475);

// babel-minify and Closure Compiler transpiles RegExp('(?<a>b)', 'g') -> /(?<a>b)/g and it causes SyntaxError
var $RegExp = global.RegExp;

module.exports = fails(function () {
  var re = $RegExp('(?<a>b)', 'g');
  return re.exec('b').groups.a !== 'b' ||
    'b'.replace(re, '$<a>c') !== 'bc';
});


/***/ }),

/***/ 7750:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var isNullOrUndefined = __webpack_require__(4117);

var $TypeError = TypeError;

// `RequireObjectCoercible` abstract operation
// https://tc39.es/ecma262/#sec-requireobjectcoercible
module.exports = function (it) {
  if (isNullOrUndefined(it)) throw new $TypeError("Can't call method on " + it);
  return it;
};


/***/ }),

/***/ 3389:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var DESCRIPTORS = __webpack_require__(3724);

// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;

// Avoid NodeJS experimental warning
module.exports = function (name) {
  if (!DESCRIPTORS) return global[name];
  var descriptor = getOwnPropertyDescriptor(global, name);
  return descriptor && descriptor.value;
};


/***/ }),

/***/ 7633:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var getBuiltIn = __webpack_require__(7751);
var defineBuiltInAccessor = __webpack_require__(2106);
var wellKnownSymbol = __webpack_require__(8227);
var DESCRIPTORS = __webpack_require__(3724);

var SPECIES = wellKnownSymbol('species');

module.exports = function (CONSTRUCTOR_NAME) {
  var Constructor = getBuiltIn(CONSTRUCTOR_NAME);

  if (DESCRIPTORS && Constructor && !Constructor[SPECIES]) {
    defineBuiltInAccessor(Constructor, SPECIES, {
      configurable: true,
      get: function () { return this; }
    });
  }
};


/***/ }),

/***/ 687:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var defineProperty = (__webpack_require__(4913).f);
var hasOwn = __webpack_require__(9297);
var wellKnownSymbol = __webpack_require__(8227);

var TO_STRING_TAG = wellKnownSymbol('toStringTag');

module.exports = function (target, TAG, STATIC) {
  if (target && !STATIC) target = target.prototype;
  if (target && !hasOwn(target, TO_STRING_TAG)) {
    defineProperty(target, TO_STRING_TAG, { configurable: true, value: TAG });
  }
};


/***/ }),

/***/ 6119:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var shared = __webpack_require__(5745);
var uid = __webpack_require__(3392);

var keys = shared('keys');

module.exports = function (key) {
  return keys[key] || (keys[key] = uid(key));
};


/***/ }),

/***/ 7629:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var IS_PURE = __webpack_require__(6395);
var globalThis = __webpack_require__(4475);
var defineGlobalProperty = __webpack_require__(9433);

var SHARED = '__core-js_shared__';
var store = module.exports = globalThis[SHARED] || defineGlobalProperty(SHARED, {});

(store.versions || (store.versions = [])).push({
  version: '3.36.0',
  mode: IS_PURE ? 'pure' : 'global',
  copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
  license: 'https://github.com/zloirock/core-js/blob/v3.36.0/LICENSE',
  source: 'https://github.com/zloirock/core-js'
});


/***/ }),

/***/ 5745:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var store = __webpack_require__(7629);

module.exports = function (key, value) {
  return store[key] || (store[key] = value || {});
};


/***/ }),

/***/ 2293:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var anObject = __webpack_require__(8551);
var aConstructor = __webpack_require__(5548);
var isNullOrUndefined = __webpack_require__(4117);
var wellKnownSymbol = __webpack_require__(8227);

var SPECIES = wellKnownSymbol('species');

// `SpeciesConstructor` abstract operation
// https://tc39.es/ecma262/#sec-speciesconstructor
module.exports = function (O, defaultConstructor) {
  var C = anObject(O).constructor;
  var S;
  return C === undefined || isNullOrUndefined(S = anObject(C)[SPECIES]) ? defaultConstructor : aConstructor(S);
};


/***/ }),

/***/ 8183:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var toIntegerOrInfinity = __webpack_require__(1291);
var toString = __webpack_require__(655);
var requireObjectCoercible = __webpack_require__(7750);

var charAt = uncurryThis(''.charAt);
var charCodeAt = uncurryThis(''.charCodeAt);
var stringSlice = uncurryThis(''.slice);

var createMethod = function (CONVERT_TO_STRING) {
  return function ($this, pos) {
    var S = toString(requireObjectCoercible($this));
    var position = toIntegerOrInfinity(pos);
    var size = S.length;
    var first, second;
    if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;
    first = charCodeAt(S, position);
    return first < 0xD800 || first > 0xDBFF || position + 1 === size
      || (second = charCodeAt(S, position + 1)) < 0xDC00 || second > 0xDFFF
        ? CONVERT_TO_STRING
          ? charAt(S, position)
          : first
        : CONVERT_TO_STRING
          ? stringSlice(S, position, position + 2)
          : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;
  };
};

module.exports = {
  // `String.prototype.codePointAt` method
  // https://tc39.es/ecma262/#sec-string.prototype.codepointat
  codeAt: createMethod(false),
  // `String.prototype.at` method
  // https://github.com/mathiasbynens/String.prototype.at
  charAt: createMethod(true)
};


/***/ }),

/***/ 6098:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


// based on https://github.com/bestiejs/punycode.js/blob/master/punycode.js
var uncurryThis = __webpack_require__(9504);

var maxInt = 2147483647; // aka. 0x7FFFFFFF or 2^31-1
var base = 36;
var tMin = 1;
var tMax = 26;
var skew = 38;
var damp = 700;
var initialBias = 72;
var initialN = 128; // 0x80
var delimiter = '-'; // '\x2D'
var regexNonASCII = /[^\0-\u007E]/; // non-ASCII chars
var regexSeparators = /[.\u3002\uFF0E\uFF61]/g; // RFC 3490 separators
var OVERFLOW_ERROR = 'Overflow: input needs wider integers to process';
var baseMinusTMin = base - tMin;

var $RangeError = RangeError;
var exec = uncurryThis(regexSeparators.exec);
var floor = Math.floor;
var fromCharCode = String.fromCharCode;
var charCodeAt = uncurryThis(''.charCodeAt);
var join = uncurryThis([].join);
var push = uncurryThis([].push);
var replace = uncurryThis(''.replace);
var split = uncurryThis(''.split);
var toLowerCase = uncurryThis(''.toLowerCase);

/**
 * Creates an array containing the numeric code points of each Unicode
 * character in the string. While JavaScript uses UCS-2 internally,
 * this function will convert a pair of surrogate halves (each of which
 * UCS-2 exposes as separate characters) into a single code point,
 * matching UTF-16.
 */
var ucs2decode = function (string) {
  var output = [];
  var counter = 0;
  var length = string.length;
  while (counter < length) {
    var value = charCodeAt(string, counter++);
    if (value >= 0xD800 && value <= 0xDBFF && counter < length) {
      // It's a high surrogate, and there is a next character.
      var extra = charCodeAt(string, counter++);
      if ((extra & 0xFC00) === 0xDC00) { // Low surrogate.
        push(output, ((value & 0x3FF) << 10) + (extra & 0x3FF) + 0x10000);
      } else {
        // It's an unmatched surrogate; only append this code unit, in case the
        // next code unit is the high surrogate of a surrogate pair.
        push(output, value);
        counter--;
      }
    } else {
      push(output, value);
    }
  }
  return output;
};

/**
 * Converts a digit/integer into a basic code point.
 */
var digitToBasic = function (digit) {
  //  0..25 map to ASCII a..z or A..Z
  // 26..35 map to ASCII 0..9
  return digit + 22 + 75 * (digit < 26);
};

/**
 * Bias adaptation function as per section 3.4 of RFC 3492.
 * https://tools.ietf.org/html/rfc3492#section-3.4
 */
var adapt = function (delta, numPoints, firstTime) {
  var k = 0;
  delta = firstTime ? floor(delta / damp) : delta >> 1;
  delta += floor(delta / numPoints);
  while (delta > baseMinusTMin * tMax >> 1) {
    delta = floor(delta / baseMinusTMin);
    k += base;
  }
  return floor(k + (baseMinusTMin + 1) * delta / (delta + skew));
};

/**
 * Converts a string of Unicode symbols (e.g. a domain name label) to a
 * Punycode string of ASCII-only symbols.
 */
var encode = function (input) {
  var output = [];

  // Convert the input in UCS-2 to an array of Unicode code points.
  input = ucs2decode(input);

  // Cache the length.
  var inputLength = input.length;

  // Initialize the state.
  var n = initialN;
  var delta = 0;
  var bias = initialBias;
  var i, currentValue;

  // Handle the basic code points.
  for (i = 0; i < input.length; i++) {
    currentValue = input[i];
    if (currentValue < 0x80) {
      push(output, fromCharCode(currentValue));
    }
  }

  var basicLength = output.length; // number of basic code points.
  var handledCPCount = basicLength; // number of code points that have been handled;

  // Finish the basic string with a delimiter unless it's empty.
  if (basicLength) {
    push(output, delimiter);
  }

  // Main encoding loop:
  while (handledCPCount < inputLength) {
    // All non-basic code points < n have been handled already. Find the next larger one:
    var m = maxInt;
    for (i = 0; i < input.length; i++) {
      currentValue = input[i];
      if (currentValue >= n && currentValue < m) {
        m = currentValue;
      }
    }

    // Increase `delta` enough to advance the decoder's <n,i> state to <m,0>, but guard against overflow.
    var handledCPCountPlusOne = handledCPCount + 1;
    if (m - n > floor((maxInt - delta) / handledCPCountPlusOne)) {
      throw new $RangeError(OVERFLOW_ERROR);
    }

    delta += (m - n) * handledCPCountPlusOne;
    n = m;

    for (i = 0; i < input.length; i++) {
      currentValue = input[i];
      if (currentValue < n && ++delta > maxInt) {
        throw new $RangeError(OVERFLOW_ERROR);
      }
      if (currentValue === n) {
        // Represent delta as a generalized variable-length integer.
        var q = delta;
        var k = base;
        while (true) {
          var t = k <= bias ? tMin : k >= bias + tMax ? tMax : k - bias;
          if (q < t) break;
          var qMinusT = q - t;
          var baseMinusT = base - t;
          push(output, fromCharCode(digitToBasic(t + qMinusT % baseMinusT)));
          q = floor(qMinusT / baseMinusT);
          k += base;
        }

        push(output, fromCharCode(digitToBasic(q)));
        bias = adapt(delta, handledCPCountPlusOne, handledCPCount === basicLength);
        delta = 0;
        handledCPCount++;
      }
    }

    delta++;
    n++;
  }
  return join(output, '');
};

module.exports = function (input) {
  var encoded = [];
  var labels = split(replace(toLowerCase(input), regexSeparators, '\u002E'), '.');
  var i, label;
  for (i = 0; i < labels.length; i++) {
    label = labels[i];
    push(encoded, exec(regexNonASCII, label) ? 'xn--' + encode(label) : label);
  }
  return join(encoded, '.');
};


/***/ }),

/***/ 3802:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var requireObjectCoercible = __webpack_require__(7750);
var toString = __webpack_require__(655);
var whitespaces = __webpack_require__(7452);

var replace = uncurryThis(''.replace);
var ltrim = RegExp('^[' + whitespaces + ']+');
var rtrim = RegExp('(^|[^' + whitespaces + '])[' + whitespaces + ']+$');

// `String.prototype.{ trim, trimStart, trimEnd, trimLeft, trimRight }` methods implementation
var createMethod = function (TYPE) {
  return function ($this) {
    var string = toString(requireObjectCoercible($this));
    if (TYPE & 1) string = replace(string, ltrim, '');
    if (TYPE & 2) string = replace(string, rtrim, '$1');
    return string;
  };
};

module.exports = {
  // `String.prototype.{ trimLeft, trimStart }` methods
  // https://tc39.es/ecma262/#sec-string.prototype.trimstart
  start: createMethod(1),
  // `String.prototype.{ trimRight, trimEnd }` methods
  // https://tc39.es/ecma262/#sec-string.prototype.trimend
  end: createMethod(2),
  // `String.prototype.trim` method
  // https://tc39.es/ecma262/#sec-string.prototype.trim
  trim: createMethod(3)
};


/***/ }),

/***/ 1548:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var fails = __webpack_require__(9039);
var V8 = __webpack_require__(7388);
var IS_BROWSER = __webpack_require__(7290);
var IS_DENO = __webpack_require__(516);
var IS_NODE = __webpack_require__(9088);

var structuredClone = global.structuredClone;

module.exports = !!structuredClone && !fails(function () {
  // prevent V8 ArrayBufferDetaching protector cell invalidation and performance degradation
  // https://github.com/zloirock/core-js/issues/679
  if ((IS_DENO && V8 > 92) || (IS_NODE && V8 > 94) || (IS_BROWSER && V8 > 97)) return false;
  var buffer = new ArrayBuffer(8);
  var clone = structuredClone(buffer, { transfer: [buffer] });
  return buffer.byteLength !== 0 || clone.byteLength !== 8;
});


/***/ }),

/***/ 4495:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable es/no-symbol -- required for testing */
var V8_VERSION = __webpack_require__(7388);
var fails = __webpack_require__(9039);
var global = __webpack_require__(4475);

var $String = global.String;

// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
module.exports = !!Object.getOwnPropertySymbols && !fails(function () {
  var symbol = Symbol('symbol detection');
  // Chrome 38 Symbol has incorrect toString conversion
  // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
  // nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
  // of course, fail.
  return !$String(symbol) || !(Object(symbol) instanceof Symbol) ||
    // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
    !Symbol.sham && V8_VERSION && V8_VERSION < 41;
});


/***/ }),

/***/ 8242:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var call = __webpack_require__(9565);
var getBuiltIn = __webpack_require__(7751);
var wellKnownSymbol = __webpack_require__(8227);
var defineBuiltIn = __webpack_require__(6840);

module.exports = function () {
  var Symbol = getBuiltIn('Symbol');
  var SymbolPrototype = Symbol && Symbol.prototype;
  var valueOf = SymbolPrototype && SymbolPrototype.valueOf;
  var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');

  if (SymbolPrototype && !SymbolPrototype[TO_PRIMITIVE]) {
    // `Symbol.prototype[@@toPrimitive]` method
    // https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive
    // eslint-disable-next-line no-unused-vars -- required for .length
    defineBuiltIn(SymbolPrototype, TO_PRIMITIVE, function (hint) {
      return call(valueOf, this);
    }, { arity: 1 });
  }
};


/***/ }),

/***/ 1296:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var NATIVE_SYMBOL = __webpack_require__(4495);

/* eslint-disable es/no-symbol -- safe */
module.exports = NATIVE_SYMBOL && !!Symbol['for'] && !!Symbol.keyFor;


/***/ }),

/***/ 9225:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var apply = __webpack_require__(8745);
var bind = __webpack_require__(6080);
var isCallable = __webpack_require__(4901);
var hasOwn = __webpack_require__(9297);
var fails = __webpack_require__(9039);
var html = __webpack_require__(397);
var arraySlice = __webpack_require__(7680);
var createElement = __webpack_require__(4055);
var validateArgumentsLength = __webpack_require__(2812);
var IS_IOS = __webpack_require__(8119);
var IS_NODE = __webpack_require__(9088);

var set = global.setImmediate;
var clear = global.clearImmediate;
var process = global.process;
var Dispatch = global.Dispatch;
var Function = global.Function;
var MessageChannel = global.MessageChannel;
var String = global.String;
var counter = 0;
var queue = {};
var ONREADYSTATECHANGE = 'onreadystatechange';
var $location, defer, channel, port;

fails(function () {
  // Deno throws a ReferenceError on `location` access without `--location` flag
  $location = global.location;
});

var run = function (id) {
  if (hasOwn(queue, id)) {
    var fn = queue[id];
    delete queue[id];
    fn();
  }
};

var runner = function (id) {
  return function () {
    run(id);
  };
};

var eventListener = function (event) {
  run(event.data);
};

var globalPostMessageDefer = function (id) {
  // old engines have not location.origin
  global.postMessage(String(id), $location.protocol + '//' + $location.host);
};

// Node.js 0.9+ & IE10+ has setImmediate, otherwise:
if (!set || !clear) {
  set = function setImmediate(handler) {
    validateArgumentsLength(arguments.length, 1);
    var fn = isCallable(handler) ? handler : Function(handler);
    var args = arraySlice(arguments, 1);
    queue[++counter] = function () {
      apply(fn, undefined, args);
    };
    defer(counter);
    return counter;
  };
  clear = function clearImmediate(id) {
    delete queue[id];
  };
  // Node.js 0.8-
  if (IS_NODE) {
    defer = function (id) {
      process.nextTick(runner(id));
    };
  // Sphere (JS game engine) Dispatch API
  } else if (Dispatch && Dispatch.now) {
    defer = function (id) {
      Dispatch.now(runner(id));
    };
  // Browsers with MessageChannel, includes WebWorkers
  // except iOS - https://github.com/zloirock/core-js/issues/624
  } else if (MessageChannel && !IS_IOS) {
    channel = new MessageChannel();
    port = channel.port2;
    channel.port1.onmessage = eventListener;
    defer = bind(port.postMessage, port);
  // Browsers with postMessage, skip WebWorkers
  // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'
  } else if (
    global.addEventListener &&
    isCallable(global.postMessage) &&
    !global.importScripts &&
    $location && $location.protocol !== 'file:' &&
    !fails(globalPostMessageDefer)
  ) {
    defer = globalPostMessageDefer;
    global.addEventListener('message', eventListener, false);
  // IE8-
  } else if (ONREADYSTATECHANGE in createElement('script')) {
    defer = function (id) {
      html.appendChild(createElement('script'))[ONREADYSTATECHANGE] = function () {
        html.removeChild(this);
        run(id);
      };
    };
  // Rest old browsers
  } else {
    defer = function (id) {
      setTimeout(runner(id), 0);
    };
  }
}

module.exports = {
  set: set,
  clear: clear
};


/***/ }),

/***/ 1240:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);

// `thisNumberValue` abstract operation
// https://tc39.es/ecma262/#sec-thisnumbervalue
module.exports = uncurryThis(1.0.valueOf);


/***/ }),

/***/ 5610:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toIntegerOrInfinity = __webpack_require__(1291);

var max = Math.max;
var min = Math.min;

// Helper for a popular repeating case of the spec:
// Let integer be ? ToInteger(index).
// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
module.exports = function (index, length) {
  var integer = toIntegerOrInfinity(index);
  return integer < 0 ? max(integer + length, 0) : min(integer, length);
};


/***/ }),

/***/ 5854:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toPrimitive = __webpack_require__(2777);

var $TypeError = TypeError;

// `ToBigInt` abstract operation
// https://tc39.es/ecma262/#sec-tobigint
module.exports = function (argument) {
  var prim = toPrimitive(argument, 'number');
  if (typeof prim == 'number') throw new $TypeError("Can't convert number to bigint");
  // eslint-disable-next-line es/no-bigint -- safe
  return BigInt(prim);
};


/***/ }),

/***/ 7696:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toIntegerOrInfinity = __webpack_require__(1291);
var toLength = __webpack_require__(8014);

var $RangeError = RangeError;

// `ToIndex` abstract operation
// https://tc39.es/ecma262/#sec-toindex
module.exports = function (it) {
  if (it === undefined) return 0;
  var number = toIntegerOrInfinity(it);
  var length = toLength(number);
  if (number !== length) throw new $RangeError('Wrong length or index');
  return length;
};


/***/ }),

/***/ 5397:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


// toObject with fallback for non-array-like ES3 strings
var IndexedObject = __webpack_require__(7055);
var requireObjectCoercible = __webpack_require__(7750);

module.exports = function (it) {
  return IndexedObject(requireObjectCoercible(it));
};


/***/ }),

/***/ 1291:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var trunc = __webpack_require__(741);

// `ToIntegerOrInfinity` abstract operation
// https://tc39.es/ecma262/#sec-tointegerorinfinity
module.exports = function (argument) {
  var number = +argument;
  // eslint-disable-next-line no-self-compare -- NaN check
  return number !== number || number === 0 ? 0 : trunc(number);
};


/***/ }),

/***/ 8014:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toIntegerOrInfinity = __webpack_require__(1291);

var min = Math.min;

// `ToLength` abstract operation
// https://tc39.es/ecma262/#sec-tolength
module.exports = function (argument) {
  var len = toIntegerOrInfinity(argument);
  return len > 0 ? min(len, 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
};


/***/ }),

/***/ 8981:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var requireObjectCoercible = __webpack_require__(7750);

var $Object = Object;

// `ToObject` abstract operation
// https://tc39.es/ecma262/#sec-toobject
module.exports = function (argument) {
  return $Object(requireObjectCoercible(argument));
};


/***/ }),

/***/ 8229:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toPositiveInteger = __webpack_require__(9590);

var $RangeError = RangeError;

module.exports = function (it, BYTES) {
  var offset = toPositiveInteger(it);
  if (offset % BYTES) throw new $RangeError('Wrong offset');
  return offset;
};


/***/ }),

/***/ 9590:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toIntegerOrInfinity = __webpack_require__(1291);

var $RangeError = RangeError;

module.exports = function (it) {
  var result = toIntegerOrInfinity(it);
  if (result < 0) throw new $RangeError("The argument can't be less than 0");
  return result;
};


/***/ }),

/***/ 2777:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var call = __webpack_require__(9565);
var isObject = __webpack_require__(34);
var isSymbol = __webpack_require__(757);
var getMethod = __webpack_require__(5966);
var ordinaryToPrimitive = __webpack_require__(4270);
var wellKnownSymbol = __webpack_require__(8227);

var $TypeError = TypeError;
var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');

// `ToPrimitive` abstract operation
// https://tc39.es/ecma262/#sec-toprimitive
module.exports = function (input, pref) {
  if (!isObject(input) || isSymbol(input)) return input;
  var exoticToPrim = getMethod(input, TO_PRIMITIVE);
  var result;
  if (exoticToPrim) {
    if (pref === undefined) pref = 'default';
    result = call(exoticToPrim, input, pref);
    if (!isObject(result) || isSymbol(result)) return result;
    throw new $TypeError("Can't convert object to primitive value");
  }
  if (pref === undefined) pref = 'number';
  return ordinaryToPrimitive(input, pref);
};


/***/ }),

/***/ 6969:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toPrimitive = __webpack_require__(2777);
var isSymbol = __webpack_require__(757);

// `ToPropertyKey` abstract operation
// https://tc39.es/ecma262/#sec-topropertykey
module.exports = function (argument) {
  var key = toPrimitive(argument, 'string');
  return isSymbol(key) ? key : key + '';
};


/***/ }),

/***/ 2140:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var wellKnownSymbol = __webpack_require__(8227);

var TO_STRING_TAG = wellKnownSymbol('toStringTag');
var test = {};

test[TO_STRING_TAG] = 'z';

module.exports = String(test) === '[object z]';


/***/ }),

/***/ 655:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var classof = __webpack_require__(6955);

var $String = String;

module.exports = function (argument) {
  if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
  return $String(argument);
};


/***/ }),

/***/ 8319:
/***/ (function(module) {


var round = Math.round;

module.exports = function (it) {
  var value = round(it);
  return value < 0 ? 0 : value > 0xFF ? 0xFF : value & 0xFF;
};


/***/ }),

/***/ 9714:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var IS_NODE = __webpack_require__(9088);

module.exports = function (name) {
  try {
    // eslint-disable-next-line no-new-func -- safe
    if (IS_NODE) return Function('return require("' + name + '")')();
  } catch (error) { /* empty */ }
};


/***/ }),

/***/ 6823:
/***/ (function(module) {


var $String = String;

module.exports = function (argument) {
  try {
    return $String(argument);
  } catch (error) {
    return 'Object';
  }
};


/***/ }),

/***/ 5823:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var global = __webpack_require__(4475);
var call = __webpack_require__(9565);
var DESCRIPTORS = __webpack_require__(3724);
var TYPED_ARRAYS_CONSTRUCTORS_REQUIRES_WRAPPERS = __webpack_require__(2805);
var ArrayBufferViewCore = __webpack_require__(4644);
var ArrayBufferModule = __webpack_require__(6346);
var anInstance = __webpack_require__(679);
var createPropertyDescriptor = __webpack_require__(6980);
var createNonEnumerableProperty = __webpack_require__(6699);
var isIntegralNumber = __webpack_require__(2087);
var toLength = __webpack_require__(8014);
var toIndex = __webpack_require__(7696);
var toOffset = __webpack_require__(8229);
var toUint8Clamped = __webpack_require__(8319);
var toPropertyKey = __webpack_require__(6969);
var hasOwn = __webpack_require__(9297);
var classof = __webpack_require__(6955);
var isObject = __webpack_require__(34);
var isSymbol = __webpack_require__(757);
var create = __webpack_require__(2360);
var isPrototypeOf = __webpack_require__(1625);
var setPrototypeOf = __webpack_require__(2967);
var getOwnPropertyNames = (__webpack_require__(8480).f);
var typedArrayFrom = __webpack_require__(3251);
var forEach = (__webpack_require__(9213).forEach);
var setSpecies = __webpack_require__(7633);
var defineBuiltInAccessor = __webpack_require__(2106);
var definePropertyModule = __webpack_require__(4913);
var getOwnPropertyDescriptorModule = __webpack_require__(7347);
var arrayFromConstructorAndList = __webpack_require__(5370);
var InternalStateModule = __webpack_require__(1181);
var inheritIfRequired = __webpack_require__(3167);

var getInternalState = InternalStateModule.get;
var setInternalState = InternalStateModule.set;
var enforceInternalState = InternalStateModule.enforce;
var nativeDefineProperty = definePropertyModule.f;
var nativeGetOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
var RangeError = global.RangeError;
var ArrayBuffer = ArrayBufferModule.ArrayBuffer;
var ArrayBufferPrototype = ArrayBuffer.prototype;
var DataView = ArrayBufferModule.DataView;
var NATIVE_ARRAY_BUFFER_VIEWS = ArrayBufferViewCore.NATIVE_ARRAY_BUFFER_VIEWS;
var TYPED_ARRAY_TAG = ArrayBufferViewCore.TYPED_ARRAY_TAG;
var TypedArray = ArrayBufferViewCore.TypedArray;
var TypedArrayPrototype = ArrayBufferViewCore.TypedArrayPrototype;
var isTypedArray = ArrayBufferViewCore.isTypedArray;
var BYTES_PER_ELEMENT = 'BYTES_PER_ELEMENT';
var WRONG_LENGTH = 'Wrong length';

var addGetter = function (it, key) {
  defineBuiltInAccessor(it, key, {
    configurable: true,
    get: function () {
      return getInternalState(this)[key];
    }
  });
};

var isArrayBuffer = function (it) {
  var klass;
  return isPrototypeOf(ArrayBufferPrototype, it) || (klass = classof(it)) === 'ArrayBuffer' || klass === 'SharedArrayBuffer';
};

var isTypedArrayIndex = function (target, key) {
  return isTypedArray(target)
    && !isSymbol(key)
    && key in target
    && isIntegralNumber(+key)
    && key >= 0;
};

var wrappedGetOwnPropertyDescriptor = function getOwnPropertyDescriptor(target, key) {
  key = toPropertyKey(key);
  return isTypedArrayIndex(target, key)
    ? createPropertyDescriptor(2, target[key])
    : nativeGetOwnPropertyDescriptor(target, key);
};

var wrappedDefineProperty = function defineProperty(target, key, descriptor) {
  key = toPropertyKey(key);
  if (isTypedArrayIndex(target, key)
    && isObject(descriptor)
    && hasOwn(descriptor, 'value')
    && !hasOwn(descriptor, 'get')
    && !hasOwn(descriptor, 'set')
    // TODO: add validation descriptor w/o calling accessors
    && !descriptor.configurable
    && (!hasOwn(descriptor, 'writable') || descriptor.writable)
    && (!hasOwn(descriptor, 'enumerable') || descriptor.enumerable)
  ) {
    target[key] = descriptor.value;
    return target;
  } return nativeDefineProperty(target, key, descriptor);
};

if (DESCRIPTORS) {
  if (!NATIVE_ARRAY_BUFFER_VIEWS) {
    getOwnPropertyDescriptorModule.f = wrappedGetOwnPropertyDescriptor;
    definePropertyModule.f = wrappedDefineProperty;
    addGetter(TypedArrayPrototype, 'buffer');
    addGetter(TypedArrayPrototype, 'byteOffset');
    addGetter(TypedArrayPrototype, 'byteLength');
    addGetter(TypedArrayPrototype, 'length');
  }

  $({ target: 'Object', stat: true, forced: !NATIVE_ARRAY_BUFFER_VIEWS }, {
    getOwnPropertyDescriptor: wrappedGetOwnPropertyDescriptor,
    defineProperty: wrappedDefineProperty
  });

  module.exports = function (TYPE, wrapper, CLAMPED) {
    var BYTES = TYPE.match(/\d+/)[0] / 8;
    var CONSTRUCTOR_NAME = TYPE + (CLAMPED ? 'Clamped' : '') + 'Array';
    var GETTER = 'get' + TYPE;
    var SETTER = 'set' + TYPE;
    var NativeTypedArrayConstructor = global[CONSTRUCTOR_NAME];
    var TypedArrayConstructor = NativeTypedArrayConstructor;
    var TypedArrayConstructorPrototype = TypedArrayConstructor && TypedArrayConstructor.prototype;
    var exported = {};

    var getter = function (that, index) {
      var data = getInternalState(that);
      return data.view[GETTER](index * BYTES + data.byteOffset, true);
    };

    var setter = function (that, index, value) {
      var data = getInternalState(that);
      data.view[SETTER](index * BYTES + data.byteOffset, CLAMPED ? toUint8Clamped(value) : value, true);
    };

    var addElement = function (that, index) {
      nativeDefineProperty(that, index, {
        get: function () {
          return getter(this, index);
        },
        set: function (value) {
          return setter(this, index, value);
        },
        enumerable: true
      });
    };

    if (!NATIVE_ARRAY_BUFFER_VIEWS) {
      TypedArrayConstructor = wrapper(function (that, data, offset, $length) {
        anInstance(that, TypedArrayConstructorPrototype);
        var index = 0;
        var byteOffset = 0;
        var buffer, byteLength, length;
        if (!isObject(data)) {
          length = toIndex(data);
          byteLength = length * BYTES;
          buffer = new ArrayBuffer(byteLength);
        } else if (isArrayBuffer(data)) {
          buffer = data;
          byteOffset = toOffset(offset, BYTES);
          var $len = data.byteLength;
          if ($length === undefined) {
            if ($len % BYTES) throw new RangeError(WRONG_LENGTH);
            byteLength = $len - byteOffset;
            if (byteLength < 0) throw new RangeError(WRONG_LENGTH);
          } else {
            byteLength = toLength($length) * BYTES;
            if (byteLength + byteOffset > $len) throw new RangeError(WRONG_LENGTH);
          }
          length = byteLength / BYTES;
        } else if (isTypedArray(data)) {
          return arrayFromConstructorAndList(TypedArrayConstructor, data);
        } else {
          return call(typedArrayFrom, TypedArrayConstructor, data);
        }
        setInternalState(that, {
          buffer: buffer,
          byteOffset: byteOffset,
          byteLength: byteLength,
          length: length,
          view: new DataView(buffer)
        });
        while (index < length) addElement(that, index++);
      });

      if (setPrototypeOf) setPrototypeOf(TypedArrayConstructor, TypedArray);
      TypedArrayConstructorPrototype = TypedArrayConstructor.prototype = create(TypedArrayPrototype);
    } else if (TYPED_ARRAYS_CONSTRUCTORS_REQUIRES_WRAPPERS) {
      TypedArrayConstructor = wrapper(function (dummy, data, typedArrayOffset, $length) {
        anInstance(dummy, TypedArrayConstructorPrototype);
        return inheritIfRequired(function () {
          if (!isObject(data)) return new NativeTypedArrayConstructor(toIndex(data));
          if (isArrayBuffer(data)) return $length !== undefined
            ? new NativeTypedArrayConstructor(data, toOffset(typedArrayOffset, BYTES), $length)
            : typedArrayOffset !== undefined
              ? new NativeTypedArrayConstructor(data, toOffset(typedArrayOffset, BYTES))
              : new NativeTypedArrayConstructor(data);
          if (isTypedArray(data)) return arrayFromConstructorAndList(TypedArrayConstructor, data);
          return call(typedArrayFrom, TypedArrayConstructor, data);
        }(), dummy, TypedArrayConstructor);
      });

      if (setPrototypeOf) setPrototypeOf(TypedArrayConstructor, TypedArray);
      forEach(getOwnPropertyNames(NativeTypedArrayConstructor), function (key) {
        if (!(key in TypedArrayConstructor)) {
          createNonEnumerableProperty(TypedArrayConstructor, key, NativeTypedArrayConstructor[key]);
        }
      });
      TypedArrayConstructor.prototype = TypedArrayConstructorPrototype;
    }

    if (TypedArrayConstructorPrototype.constructor !== TypedArrayConstructor) {
      createNonEnumerableProperty(TypedArrayConstructorPrototype, 'constructor', TypedArrayConstructor);
    }

    enforceInternalState(TypedArrayConstructorPrototype).TypedArrayConstructor = TypedArrayConstructor;

    if (TYPED_ARRAY_TAG) {
      createNonEnumerableProperty(TypedArrayConstructorPrototype, TYPED_ARRAY_TAG, CONSTRUCTOR_NAME);
    }

    var FORCED = TypedArrayConstructor !== NativeTypedArrayConstructor;

    exported[CONSTRUCTOR_NAME] = TypedArrayConstructor;

    $({ global: true, constructor: true, forced: FORCED, sham: !NATIVE_ARRAY_BUFFER_VIEWS }, exported);

    if (!(BYTES_PER_ELEMENT in TypedArrayConstructor)) {
      createNonEnumerableProperty(TypedArrayConstructor, BYTES_PER_ELEMENT, BYTES);
    }

    if (!(BYTES_PER_ELEMENT in TypedArrayConstructorPrototype)) {
      createNonEnumerableProperty(TypedArrayConstructorPrototype, BYTES_PER_ELEMENT, BYTES);
    }

    setSpecies(CONSTRUCTOR_NAME);
  };
} else module.exports = function () { /* empty */ };


/***/ }),

/***/ 2805:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable no-new -- required for testing */
var global = __webpack_require__(4475);
var fails = __webpack_require__(9039);
var checkCorrectnessOfIteration = __webpack_require__(4428);
var NATIVE_ARRAY_BUFFER_VIEWS = (__webpack_require__(4644).NATIVE_ARRAY_BUFFER_VIEWS);

var ArrayBuffer = global.ArrayBuffer;
var Int8Array = global.Int8Array;

module.exports = !NATIVE_ARRAY_BUFFER_VIEWS || !fails(function () {
  Int8Array(1);
}) || !fails(function () {
  new Int8Array(-1);
}) || !checkCorrectnessOfIteration(function (iterable) {
  new Int8Array();
  new Int8Array(null);
  new Int8Array(1.5);
  new Int8Array(iterable);
}, true) || fails(function () {
  // Safari (11+) bug - a reason why even Safari 13 should load a typed array polyfill
  return new Int8Array(new ArrayBuffer(2), 1, undefined).length !== 1;
});


/***/ }),

/***/ 6357:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var arrayFromConstructorAndList = __webpack_require__(5370);
var typedArraySpeciesConstructor = __webpack_require__(1412);

module.exports = function (instance, list) {
  return arrayFromConstructorAndList(typedArraySpeciesConstructor(instance), list);
};


/***/ }),

/***/ 3251:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var bind = __webpack_require__(6080);
var call = __webpack_require__(9565);
var aConstructor = __webpack_require__(5548);
var toObject = __webpack_require__(8981);
var lengthOfArrayLike = __webpack_require__(6198);
var getIterator = __webpack_require__(81);
var getIteratorMethod = __webpack_require__(851);
var isArrayIteratorMethod = __webpack_require__(4209);
var isBigIntArray = __webpack_require__(1108);
var aTypedArrayConstructor = (__webpack_require__(4644).aTypedArrayConstructor);
var toBigInt = __webpack_require__(5854);

module.exports = function from(source /* , mapfn, thisArg */) {
  var C = aConstructor(this);
  var O = toObject(source);
  var argumentsLength = arguments.length;
  var mapfn = argumentsLength > 1 ? arguments[1] : undefined;
  var mapping = mapfn !== undefined;
  var iteratorMethod = getIteratorMethod(O);
  var i, length, result, thisIsBigIntArray, value, step, iterator, next;
  if (iteratorMethod && !isArrayIteratorMethod(iteratorMethod)) {
    iterator = getIterator(O, iteratorMethod);
    next = iterator.next;
    O = [];
    while (!(step = call(next, iterator)).done) {
      O.push(step.value);
    }
  }
  if (mapping && argumentsLength > 2) {
    mapfn = bind(mapfn, arguments[2]);
  }
  length = lengthOfArrayLike(O);
  result = new (aTypedArrayConstructor(C))(length);
  thisIsBigIntArray = isBigIntArray(result);
  for (i = 0; length > i; i++) {
    value = mapping ? mapfn(O[i], i) : O[i];
    // FF30- typed arrays doesn't properly convert objects to typed array values
    result[i] = thisIsBigIntArray ? toBigInt(value) : +value;
  }
  return result;
};


/***/ }),

/***/ 1412:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var speciesConstructor = __webpack_require__(2293);

var aTypedArrayConstructor = ArrayBufferViewCore.aTypedArrayConstructor;
var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;

// a part of `TypedArraySpeciesCreate` abstract operation
// https://tc39.es/ecma262/#typedarray-species-create
module.exports = function (originalArray) {
  return aTypedArrayConstructor(speciesConstructor(originalArray, getTypedArrayConstructor(originalArray)));
};


/***/ }),

/***/ 3392:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);

var id = 0;
var postfix = Math.random();
var toString = uncurryThis(1.0.toString);

module.exports = function (key) {
  return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);
};


/***/ }),

/***/ 7416:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var fails = __webpack_require__(9039);
var wellKnownSymbol = __webpack_require__(8227);
var DESCRIPTORS = __webpack_require__(3724);
var IS_PURE = __webpack_require__(6395);

var ITERATOR = wellKnownSymbol('iterator');

module.exports = !fails(function () {
  // eslint-disable-next-line unicorn/relative-url-style -- required for testing
  var url = new URL('b?a=1&b=2&c=3', 'http://a');
  var params = url.searchParams;
  var params2 = new URLSearchParams('a=1&a=2&b=3');
  var result = '';
  url.pathname = 'c%20d';
  params.forEach(function (value, key) {
    params['delete']('b');
    result += key + value;
  });
  params2['delete']('a', 2);
  // `undefined` case is a Chromium 117 bug
  // https://bugs.chromium.org/p/v8/issues/detail?id=14222
  params2['delete']('b', undefined);
  return (IS_PURE && (!url.toJSON || !params2.has('a', 1) || params2.has('a', 2) || !params2.has('a', undefined) || params2.has('b')))
    || (!params.size && (IS_PURE || !DESCRIPTORS))
    || !params.sort
    || url.href !== 'http://a/c%20d?a=1&c=3'
    || params.get('c') !== '3'
    || String(new URLSearchParams('?a=1')) !== 'a=1'
    || !params[ITERATOR]
    // throws in Edge
    || new URL('https://a@b').username !== 'a'
    || new URLSearchParams(new URLSearchParams('a=b')).get('a') !== 'b'
    // not punycoded in Edge
    || new URL('http://тест').host !== 'xn--e1aybc'
    // not escaped in Chrome 62-
    || new URL('http://a#б').hash !== '#%D0%B1'
    // fails in Chrome 66-
    || result !== 'a1c3'
    // throws in Safari
    || new URL('http://x', undefined).host !== 'x';
});


/***/ }),

/***/ 7040:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable es/no-symbol -- required for testing */
var NATIVE_SYMBOL = __webpack_require__(4495);

module.exports = NATIVE_SYMBOL
  && !Symbol.sham
  && typeof Symbol.iterator == 'symbol';


/***/ }),

/***/ 8686:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var fails = __webpack_require__(9039);

// V8 ~ Chrome 36-
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
module.exports = DESCRIPTORS && fails(function () {
  // eslint-disable-next-line es/no-object-defineproperty -- required for testing
  return Object.defineProperty(function () { /* empty */ }, 'prototype', {
    value: 42,
    writable: false
  }).prototype !== 42;
});


/***/ }),

/***/ 2812:
/***/ (function(module) {


var $TypeError = TypeError;

module.exports = function (passed, required) {
  if (passed < required) throw new $TypeError('Not enough arguments');
  return passed;
};


/***/ }),

/***/ 8622:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var isCallable = __webpack_require__(4901);

var WeakMap = global.WeakMap;

module.exports = isCallable(WeakMap) && /native code/.test(String(WeakMap));


/***/ }),

/***/ 511:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var path = __webpack_require__(9167);
var hasOwn = __webpack_require__(9297);
var wrappedWellKnownSymbolModule = __webpack_require__(1951);
var defineProperty = (__webpack_require__(4913).f);

module.exports = function (NAME) {
  var Symbol = path.Symbol || (path.Symbol = {});
  if (!hasOwn(Symbol, NAME)) defineProperty(Symbol, NAME, {
    value: wrappedWellKnownSymbolModule.f(NAME)
  });
};


/***/ }),

/***/ 1951:
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {


var wellKnownSymbol = __webpack_require__(8227);

exports.f = wellKnownSymbol;


/***/ }),

/***/ 8227:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var shared = __webpack_require__(5745);
var hasOwn = __webpack_require__(9297);
var uid = __webpack_require__(3392);
var NATIVE_SYMBOL = __webpack_require__(4495);
var USE_SYMBOL_AS_UID = __webpack_require__(7040);

var Symbol = global.Symbol;
var WellKnownSymbolsStore = shared('wks');
var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol['for'] || Symbol : Symbol && Symbol.withoutSetter || uid;

module.exports = function (name) {
  if (!hasOwn(WellKnownSymbolsStore, name)) {
    WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn(Symbol, name)
      ? Symbol[name]
      : createWellKnownSymbol('Symbol.' + name);
  } return WellKnownSymbolsStore[name];
};


/***/ }),

/***/ 7452:
/***/ (function(module) {


// a string of all valid unicode whitespaces
module.exports = '\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u2000\u2001\u2002' +
  '\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF';


/***/ }),

/***/ 4601:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var getBuiltIn = __webpack_require__(7751);
var hasOwn = __webpack_require__(9297);
var createNonEnumerableProperty = __webpack_require__(6699);
var isPrototypeOf = __webpack_require__(1625);
var setPrototypeOf = __webpack_require__(2967);
var copyConstructorProperties = __webpack_require__(7740);
var proxyAccessor = __webpack_require__(1056);
var inheritIfRequired = __webpack_require__(3167);
var normalizeStringArgument = __webpack_require__(2603);
var installErrorCause = __webpack_require__(7584);
var installErrorStack = __webpack_require__(747);
var DESCRIPTORS = __webpack_require__(3724);
var IS_PURE = __webpack_require__(6395);

module.exports = function (FULL_NAME, wrapper, FORCED, IS_AGGREGATE_ERROR) {
  var STACK_TRACE_LIMIT = 'stackTraceLimit';
  var OPTIONS_POSITION = IS_AGGREGATE_ERROR ? 2 : 1;
  var path = FULL_NAME.split('.');
  var ERROR_NAME = path[path.length - 1];
  var OriginalError = getBuiltIn.apply(null, path);

  if (!OriginalError) return;

  var OriginalErrorPrototype = OriginalError.prototype;

  // V8 9.3- bug https://bugs.chromium.org/p/v8/issues/detail?id=12006
  if (!IS_PURE && hasOwn(OriginalErrorPrototype, 'cause')) delete OriginalErrorPrototype.cause;

  if (!FORCED) return OriginalError;

  var BaseError = getBuiltIn('Error');

  var WrappedError = wrapper(function (a, b) {
    var message = normalizeStringArgument(IS_AGGREGATE_ERROR ? b : a, undefined);
    var result = IS_AGGREGATE_ERROR ? new OriginalError(a) : new OriginalError();
    if (message !== undefined) createNonEnumerableProperty(result, 'message', message);
    installErrorStack(result, WrappedError, result.stack, 2);
    if (this && isPrototypeOf(OriginalErrorPrototype, this)) inheritIfRequired(result, this, WrappedError);
    if (arguments.length > OPTIONS_POSITION) installErrorCause(result, arguments[OPTIONS_POSITION]);
    return result;
  });

  WrappedError.prototype = OriginalErrorPrototype;

  if (ERROR_NAME !== 'Error') {
    if (setPrototypeOf) setPrototypeOf(WrappedError, BaseError);
    else copyConstructorProperties(WrappedError, BaseError, { name: true });
  } else if (DESCRIPTORS && STACK_TRACE_LIMIT in OriginalError) {
    proxyAccessor(WrappedError, OriginalError, STACK_TRACE_LIMIT);
    proxyAccessor(WrappedError, OriginalError, 'prepareStackTrace');
  }

  copyConstructorProperties(WrappedError, OriginalError);

  if (!IS_PURE) try {
    // Safari 13- bug: WebAssembly errors does not have a proper `.name`
    if (OriginalErrorPrototype.name !== ERROR_NAME) {
      createNonEnumerableProperty(OriginalErrorPrototype, 'name', ERROR_NAME);
    }
    OriginalErrorPrototype.constructor = WrappedError;
  } catch (error) { /* empty */ }

  return WrappedError;
};


/***/ }),

/***/ 4743:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var global = __webpack_require__(4475);
var arrayBufferModule = __webpack_require__(6346);
var setSpecies = __webpack_require__(7633);

var ARRAY_BUFFER = 'ArrayBuffer';
var ArrayBuffer = arrayBufferModule[ARRAY_BUFFER];
var NativeArrayBuffer = global[ARRAY_BUFFER];

// `ArrayBuffer` constructor
// https://tc39.es/ecma262/#sec-arraybuffer-constructor
$({ global: true, constructor: true, forced: NativeArrayBuffer !== ArrayBuffer }, {
  ArrayBuffer: ArrayBuffer
});

setSpecies(ARRAY_BUFFER);


/***/ }),

/***/ 6573:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var defineBuiltInAccessor = __webpack_require__(2106);
var isDetached = __webpack_require__(3238);

var ArrayBufferPrototype = ArrayBuffer.prototype;

if (DESCRIPTORS && !('detached' in ArrayBufferPrototype)) {
  defineBuiltInAccessor(ArrayBufferPrototype, 'detached', {
    configurable: true,
    get: function detached() {
      return isDetached(this);
    }
  });
}


/***/ }),

/***/ 1745:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var uncurryThis = __webpack_require__(7476);
var fails = __webpack_require__(9039);
var ArrayBufferModule = __webpack_require__(6346);
var anObject = __webpack_require__(8551);
var toAbsoluteIndex = __webpack_require__(5610);
var toLength = __webpack_require__(8014);
var speciesConstructor = __webpack_require__(2293);

var ArrayBuffer = ArrayBufferModule.ArrayBuffer;
var DataView = ArrayBufferModule.DataView;
var DataViewPrototype = DataView.prototype;
var nativeArrayBufferSlice = uncurryThis(ArrayBuffer.prototype.slice);
var getUint8 = uncurryThis(DataViewPrototype.getUint8);
var setUint8 = uncurryThis(DataViewPrototype.setUint8);

var INCORRECT_SLICE = fails(function () {
  return !new ArrayBuffer(2).slice(1, undefined).byteLength;
});

// `ArrayBuffer.prototype.slice` method
// https://tc39.es/ecma262/#sec-arraybuffer.prototype.slice
$({ target: 'ArrayBuffer', proto: true, unsafe: true, forced: INCORRECT_SLICE }, {
  slice: function slice(start, end) {
    if (nativeArrayBufferSlice && end === undefined) {
      return nativeArrayBufferSlice(anObject(this), start); // FF fix
    }
    var length = anObject(this).byteLength;
    var first = toAbsoluteIndex(start, length);
    var fin = toAbsoluteIndex(end === undefined ? length : end, length);
    var result = new (speciesConstructor(this, ArrayBuffer))(toLength(fin - first));
    var viewSource = new DataView(this);
    var viewTarget = new DataView(result);
    var index = 0;
    while (first < fin) {
      setUint8(viewTarget, index++, getUint8(viewSource, first++));
    } return result;
  }
});


/***/ }),

/***/ 7936:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var $transfer = __webpack_require__(5636);

// `ArrayBuffer.prototype.transferToFixedLength` method
// https://tc39.es/proposal-arraybuffer-transfer/#sec-arraybuffer.prototype.transfertofixedlength
if ($transfer) $({ target: 'ArrayBuffer', proto: true }, {
  transferToFixedLength: function transferToFixedLength() {
    return $transfer(this, arguments.length ? arguments[0] : undefined, false);
  }
});


/***/ }),

/***/ 8100:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var $transfer = __webpack_require__(5636);

// `ArrayBuffer.prototype.transfer` method
// https://tc39.es/proposal-arraybuffer-transfer/#sec-arraybuffer.prototype.transfer
if ($transfer) $({ target: 'ArrayBuffer', proto: true }, {
  transfer: function transfer() {
    return $transfer(this, arguments.length ? arguments[0] : undefined, true);
  }
});


/***/ }),

/***/ 8107:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var toObject = __webpack_require__(8981);
var lengthOfArrayLike = __webpack_require__(6198);
var toIntegerOrInfinity = __webpack_require__(1291);
var addToUnscopables = __webpack_require__(6469);

// `Array.prototype.at` method
// https://tc39.es/ecma262/#sec-array.prototype.at
$({ target: 'Array', proto: true }, {
  at: function at(index) {
    var O = toObject(this);
    var len = lengthOfArrayLike(O);
    var relativeIndex = toIntegerOrInfinity(index);
    var k = relativeIndex >= 0 ? relativeIndex : len + relativeIndex;
    return (k < 0 || k >= len) ? undefined : O[k];
  }
});

addToUnscopables('at');


/***/ }),

/***/ 8706:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var fails = __webpack_require__(9039);
var isArray = __webpack_require__(4376);
var isObject = __webpack_require__(34);
var toObject = __webpack_require__(8981);
var lengthOfArrayLike = __webpack_require__(6198);
var doesNotExceedSafeInteger = __webpack_require__(6837);
var createProperty = __webpack_require__(4659);
var arraySpeciesCreate = __webpack_require__(1469);
var arrayMethodHasSpeciesSupport = __webpack_require__(597);
var wellKnownSymbol = __webpack_require__(8227);
var V8_VERSION = __webpack_require__(7388);

var IS_CONCAT_SPREADABLE = wellKnownSymbol('isConcatSpreadable');

// We can't use this feature detection in V8 since it causes
// deoptimization and serious performance degradation
// https://github.com/zloirock/core-js/issues/679
var IS_CONCAT_SPREADABLE_SUPPORT = V8_VERSION >= 51 || !fails(function () {
  var array = [];
  array[IS_CONCAT_SPREADABLE] = false;
  return array.concat()[0] !== array;
});

var isConcatSpreadable = function (O) {
  if (!isObject(O)) return false;
  var spreadable = O[IS_CONCAT_SPREADABLE];
  return spreadable !== undefined ? !!spreadable : isArray(O);
};

var FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !arrayMethodHasSpeciesSupport('concat');

// `Array.prototype.concat` method
// https://tc39.es/ecma262/#sec-array.prototype.concat
// with adding support of @@isConcatSpreadable and @@species
$({ target: 'Array', proto: true, arity: 1, forced: FORCED }, {
  // eslint-disable-next-line no-unused-vars -- required for `.length`
  concat: function concat(arg) {
    var O = toObject(this);
    var A = arraySpeciesCreate(O, 0);
    var n = 0;
    var i, k, length, len, E;
    for (i = -1, length = arguments.length; i < length; i++) {
      E = i === -1 ? O : arguments[i];
      if (isConcatSpreadable(E)) {
        len = lengthOfArrayLike(E);
        doesNotExceedSafeInteger(n + len);
        for (k = 0; k < len; k++, n++) if (k in E) createProperty(A, n, E[k]);
      } else {
        doesNotExceedSafeInteger(n + 1);
        createProperty(A, n++, E);
      }
    }
    A.length = n;
    return A;
  }
});


/***/ }),

/***/ 3418:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var from = __webpack_require__(7916);
var checkCorrectnessOfIteration = __webpack_require__(4428);

var INCORRECT_ITERATION = !checkCorrectnessOfIteration(function (iterable) {
  // eslint-disable-next-line es/no-array-from -- required for testing
  Array.from(iterable);
});

// `Array.from` method
// https://tc39.es/ecma262/#sec-array.from
$({ target: 'Array', stat: true, forced: INCORRECT_ITERATION }, {
  from: from
});


/***/ }),

/***/ 5276:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable es/no-array-prototype-indexof -- required for testing */
var $ = __webpack_require__(6518);
var uncurryThis = __webpack_require__(7476);
var $indexOf = (__webpack_require__(9617).indexOf);
var arrayMethodIsStrict = __webpack_require__(4598);

var nativeIndexOf = uncurryThis([].indexOf);

var NEGATIVE_ZERO = !!nativeIndexOf && 1 / nativeIndexOf([1], 1, -0) < 0;
var FORCED = NEGATIVE_ZERO || !arrayMethodIsStrict('indexOf');

// `Array.prototype.indexOf` method
// https://tc39.es/ecma262/#sec-array.prototype.indexof
$({ target: 'Array', proto: true, forced: FORCED }, {
  indexOf: function indexOf(searchElement /* , fromIndex = 0 */) {
    var fromIndex = arguments.length > 1 ? arguments[1] : undefined;
    return NEGATIVE_ZERO
      // convert -0 to +0
      ? nativeIndexOf(this, searchElement, fromIndex) || 0
      : $indexOf(this, searchElement, fromIndex);
  }
});


/***/ }),

/***/ 3792:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


var toIndexedObject = __webpack_require__(5397);
var addToUnscopables = __webpack_require__(6469);
var Iterators = __webpack_require__(6269);
var InternalStateModule = __webpack_require__(1181);
var defineProperty = (__webpack_require__(4913).f);
var defineIterator = __webpack_require__(1088);
var createIterResultObject = __webpack_require__(2529);
var IS_PURE = __webpack_require__(6395);
var DESCRIPTORS = __webpack_require__(3724);

var ARRAY_ITERATOR = 'Array Iterator';
var setInternalState = InternalStateModule.set;
var getInternalState = InternalStateModule.getterFor(ARRAY_ITERATOR);

// `Array.prototype.entries` method
// https://tc39.es/ecma262/#sec-array.prototype.entries
// `Array.prototype.keys` method
// https://tc39.es/ecma262/#sec-array.prototype.keys
// `Array.prototype.values` method
// https://tc39.es/ecma262/#sec-array.prototype.values
// `Array.prototype[@@iterator]` method
// https://tc39.es/ecma262/#sec-array.prototype-@@iterator
// `CreateArrayIterator` internal method
// https://tc39.es/ecma262/#sec-createarrayiterator
module.exports = defineIterator(Array, 'Array', function (iterated, kind) {
  setInternalState(this, {
    type: ARRAY_ITERATOR,
    target: toIndexedObject(iterated), // target
    index: 0,                          // next index
    kind: kind                         // kind
  });
// `%ArrayIteratorPrototype%.next` method
// https://tc39.es/ecma262/#sec-%arrayiteratorprototype%.next
}, function () {
  var state = getInternalState(this);
  var target = state.target;
  var index = state.index++;
  if (!target || index >= target.length) {
    state.target = undefined;
    return createIterResultObject(undefined, true);
  }
  switch (state.kind) {
    case 'keys': return createIterResultObject(index, false);
    case 'values': return createIterResultObject(target[index], false);
  } return createIterResultObject([index, target[index]], false);
}, 'values');

// argumentsList[@@iterator] is %ArrayProto_values%
// https://tc39.es/ecma262/#sec-createunmappedargumentsobject
// https://tc39.es/ecma262/#sec-createmappedargumentsobject
var values = Iterators.Arguments = Iterators.Array;

// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
addToUnscopables('keys');
addToUnscopables('values');
addToUnscopables('entries');

// V8 ~ Chrome 45- bug
if (!IS_PURE && DESCRIPTORS && values.name !== 'values') try {
  defineProperty(values, 'name', { value: 'values' });
} catch (error) { /* empty */ }


/***/ }),

/***/ 8921:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var lastIndexOf = __webpack_require__(8379);

// `Array.prototype.lastIndexOf` method
// https://tc39.es/ecma262/#sec-array.prototype.lastindexof
// eslint-disable-next-line es/no-array-prototype-lastindexof -- required for testing
$({ target: 'Array', proto: true, forced: lastIndexOf !== [].lastIndexOf }, {
  lastIndexOf: lastIndexOf
});


/***/ }),

/***/ 4114:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var toObject = __webpack_require__(8981);
var lengthOfArrayLike = __webpack_require__(6198);
var setArrayLength = __webpack_require__(4527);
var doesNotExceedSafeInteger = __webpack_require__(6837);
var fails = __webpack_require__(9039);

var INCORRECT_TO_LENGTH = fails(function () {
  return [].push.call({ length: 0x100000000 }, 1) !== 4294967297;
});

// V8 <= 121 and Safari <= 15.4; FF < 23 throws InternalError
// https://bugs.chromium.org/p/v8/issues/detail?id=12681
var properErrorOnNonWritableLength = function () {
  try {
    // eslint-disable-next-line es/no-object-defineproperty -- safe
    Object.defineProperty([], 'length', { writable: false }).push();
  } catch (error) {
    return error instanceof TypeError;
  }
};

var FORCED = INCORRECT_TO_LENGTH || !properErrorOnNonWritableLength();

// `Array.prototype.push` method
// https://tc39.es/ecma262/#sec-array.prototype.push
$({ target: 'Array', proto: true, arity: 1, forced: FORCED }, {
  // eslint-disable-next-line no-unused-vars -- required for `.length`
  push: function push(item) {
    var O = toObject(this);
    var len = lengthOfArrayLike(O);
    var argCount = arguments.length;
    doesNotExceedSafeInteger(len + argCount);
    for (var i = 0; i < argCount; i++) {
      O[len] = arguments[i];
      len++;
    }
    setArrayLength(O, len);
    return len;
  }
});


/***/ }),

/***/ 4782:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var isArray = __webpack_require__(4376);
var isConstructor = __webpack_require__(3517);
var isObject = __webpack_require__(34);
var toAbsoluteIndex = __webpack_require__(5610);
var lengthOfArrayLike = __webpack_require__(6198);
var toIndexedObject = __webpack_require__(5397);
var createProperty = __webpack_require__(4659);
var wellKnownSymbol = __webpack_require__(8227);
var arrayMethodHasSpeciesSupport = __webpack_require__(597);
var nativeSlice = __webpack_require__(7680);

var HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('slice');

var SPECIES = wellKnownSymbol('species');
var $Array = Array;
var max = Math.max;

// `Array.prototype.slice` method
// https://tc39.es/ecma262/#sec-array.prototype.slice
// fallback for not array-like ES3 strings and DOM objects
$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {
  slice: function slice(start, end) {
    var O = toIndexedObject(this);
    var length = lengthOfArrayLike(O);
    var k = toAbsoluteIndex(start, length);
    var fin = toAbsoluteIndex(end === undefined ? length : end, length);
    // inline `ArraySpeciesCreate` for usage native `Array#slice` where it's possible
    var Constructor, result, n;
    if (isArray(O)) {
      Constructor = O.constructor;
      // cross-realm fallback
      if (isConstructor(Constructor) && (Constructor === $Array || isArray(Constructor.prototype))) {
        Constructor = undefined;
      } else if (isObject(Constructor)) {
        Constructor = Constructor[SPECIES];
        if (Constructor === null) Constructor = undefined;
      }
      if (Constructor === $Array || Constructor === undefined) {
        return nativeSlice(O, k, fin);
      }
    }
    result = new (Constructor === undefined ? $Array : Constructor)(max(fin - k, 0));
    for (n = 0; k < fin; k++, n++) if (k in O) createProperty(result, n, O[k]);
    result.length = n;
    return result;
  }
});


/***/ }),

/***/ 4554:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var toObject = __webpack_require__(8981);
var toAbsoluteIndex = __webpack_require__(5610);
var toIntegerOrInfinity = __webpack_require__(1291);
var lengthOfArrayLike = __webpack_require__(6198);
var setArrayLength = __webpack_require__(4527);
var doesNotExceedSafeInteger = __webpack_require__(6837);
var arraySpeciesCreate = __webpack_require__(1469);
var createProperty = __webpack_require__(4659);
var deletePropertyOrThrow = __webpack_require__(4606);
var arrayMethodHasSpeciesSupport = __webpack_require__(597);

var HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('splice');

var max = Math.max;
var min = Math.min;

// `Array.prototype.splice` method
// https://tc39.es/ecma262/#sec-array.prototype.splice
// with adding support of @@species
$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {
  splice: function splice(start, deleteCount /* , ...items */) {
    var O = toObject(this);
    var len = lengthOfArrayLike(O);
    var actualStart = toAbsoluteIndex(start, len);
    var argumentsLength = arguments.length;
    var insertCount, actualDeleteCount, A, k, from, to;
    if (argumentsLength === 0) {
      insertCount = actualDeleteCount = 0;
    } else if (argumentsLength === 1) {
      insertCount = 0;
      actualDeleteCount = len - actualStart;
    } else {
      insertCount = argumentsLength - 2;
      actualDeleteCount = min(max(toIntegerOrInfinity(deleteCount), 0), len - actualStart);
    }
    doesNotExceedSafeInteger(len + insertCount - actualDeleteCount);
    A = arraySpeciesCreate(O, actualDeleteCount);
    for (k = 0; k < actualDeleteCount; k++) {
      from = actualStart + k;
      if (from in O) createProperty(A, k, O[from]);
    }
    A.length = actualDeleteCount;
    if (insertCount < actualDeleteCount) {
      for (k = actualStart; k < len - actualDeleteCount; k++) {
        from = k + actualDeleteCount;
        to = k + insertCount;
        if (from in O) O[to] = O[from];
        else deletePropertyOrThrow(O, to);
      }
      for (k = len; k > len - actualDeleteCount + insertCount; k--) deletePropertyOrThrow(O, k - 1);
    } else if (insertCount > actualDeleteCount) {
      for (k = len - actualDeleteCount; k > actualStart; k--) {
        from = k + actualDeleteCount - 1;
        to = k + insertCount - 1;
        if (from in O) O[to] = O[from];
        else deletePropertyOrThrow(O, to);
      }
    }
    for (k = 0; k < insertCount; k++) {
      O[k + actualStart] = arguments[k + 2];
    }
    setArrayLength(O, len - actualDeleteCount + insertCount);
    return A;
  }
});


/***/ }),

/***/ 9572:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var hasOwn = __webpack_require__(9297);
var defineBuiltIn = __webpack_require__(6840);
var dateToPrimitive = __webpack_require__(3640);
var wellKnownSymbol = __webpack_require__(8227);

var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');
var DatePrototype = Date.prototype;

// `Date.prototype[@@toPrimitive]` method
// https://tc39.es/ecma262/#sec-date.prototype-@@toprimitive
if (!hasOwn(DatePrototype, TO_PRIMITIVE)) {
  defineBuiltIn(DatePrototype, TO_PRIMITIVE, dateToPrimitive);
}


/***/ }),

/***/ 6280:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


/* eslint-disable no-unused-vars -- required for functions `.length` */
var $ = __webpack_require__(6518);
var global = __webpack_require__(4475);
var apply = __webpack_require__(8745);
var wrapErrorConstructorWithCause = __webpack_require__(4601);

var WEB_ASSEMBLY = 'WebAssembly';
var WebAssembly = global[WEB_ASSEMBLY];

// eslint-disable-next-line es/no-error-cause -- feature detection
var FORCED = new Error('e', { cause: 7 }).cause !== 7;

var exportGlobalErrorCauseWrapper = function (ERROR_NAME, wrapper) {
  var O = {};
  O[ERROR_NAME] = wrapErrorConstructorWithCause(ERROR_NAME, wrapper, FORCED);
  $({ global: true, constructor: true, arity: 1, forced: FORCED }, O);
};

var exportWebAssemblyErrorCauseWrapper = function (ERROR_NAME, wrapper) {
  if (WebAssembly && WebAssembly[ERROR_NAME]) {
    var O = {};
    O[ERROR_NAME] = wrapErrorConstructorWithCause(WEB_ASSEMBLY + '.' + ERROR_NAME, wrapper, FORCED);
    $({ target: WEB_ASSEMBLY, stat: true, constructor: true, arity: 1, forced: FORCED }, O);
  }
};

// https://tc39.es/ecma262/#sec-nativeerror
exportGlobalErrorCauseWrapper('Error', function (init) {
  return function Error(message) { return apply(init, this, arguments); };
});
exportGlobalErrorCauseWrapper('EvalError', function (init) {
  return function EvalError(message) { return apply(init, this, arguments); };
});
exportGlobalErrorCauseWrapper('RangeError', function (init) {
  return function RangeError(message) { return apply(init, this, arguments); };
});
exportGlobalErrorCauseWrapper('ReferenceError', function (init) {
  return function ReferenceError(message) { return apply(init, this, arguments); };
});
exportGlobalErrorCauseWrapper('SyntaxError', function (init) {
  return function SyntaxError(message) { return apply(init, this, arguments); };
});
exportGlobalErrorCauseWrapper('TypeError', function (init) {
  return function TypeError(message) { return apply(init, this, arguments); };
});
exportGlobalErrorCauseWrapper('URIError', function (init) {
  return function URIError(message) { return apply(init, this, arguments); };
});
exportWebAssemblyErrorCauseWrapper('CompileError', function (init) {
  return function CompileError(message) { return apply(init, this, arguments); };
});
exportWebAssemblyErrorCauseWrapper('LinkError', function (init) {
  return function LinkError(message) { return apply(init, this, arguments); };
});
exportWebAssemblyErrorCauseWrapper('RuntimeError', function (init) {
  return function RuntimeError(message) { return apply(init, this, arguments); };
});


/***/ }),

/***/ 3110:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var getBuiltIn = __webpack_require__(7751);
var apply = __webpack_require__(8745);
var call = __webpack_require__(9565);
var uncurryThis = __webpack_require__(9504);
var fails = __webpack_require__(9039);
var isCallable = __webpack_require__(4901);
var isSymbol = __webpack_require__(757);
var arraySlice = __webpack_require__(7680);
var getReplacerFunction = __webpack_require__(6933);
var NATIVE_SYMBOL = __webpack_require__(4495);

var $String = String;
var $stringify = getBuiltIn('JSON', 'stringify');
var exec = uncurryThis(/./.exec);
var charAt = uncurryThis(''.charAt);
var charCodeAt = uncurryThis(''.charCodeAt);
var replace = uncurryThis(''.replace);
var numberToString = uncurryThis(1.0.toString);

var tester = /[\uD800-\uDFFF]/g;
var low = /^[\uD800-\uDBFF]$/;
var hi = /^[\uDC00-\uDFFF]$/;

var WRONG_SYMBOLS_CONVERSION = !NATIVE_SYMBOL || fails(function () {
  var symbol = getBuiltIn('Symbol')('stringify detection');
  // MS Edge converts symbol values to JSON as {}
  return $stringify([symbol]) !== '[null]'
    // WebKit converts symbol values to JSON as null
    || $stringify({ a: symbol }) !== '{}'
    // V8 throws on boxed symbols
    || $stringify(Object(symbol)) !== '{}';
});

// https://github.com/tc39/proposal-well-formed-stringify
var ILL_FORMED_UNICODE = fails(function () {
  return $stringify('\uDF06\uD834') !== '"\\udf06\\ud834"'
    || $stringify('\uDEAD') !== '"\\udead"';
});

var stringifyWithSymbolsFix = function (it, replacer) {
  var args = arraySlice(arguments);
  var $replacer = getReplacerFunction(replacer);
  if (!isCallable($replacer) && (it === undefined || isSymbol(it))) return; // IE8 returns string on undefined
  args[1] = function (key, value) {
    // some old implementations (like WebKit) could pass numbers as keys
    if (isCallable($replacer)) value = call($replacer, this, $String(key), value);
    if (!isSymbol(value)) return value;
  };
  return apply($stringify, null, args);
};

var fixIllFormed = function (match, offset, string) {
  var prev = charAt(string, offset - 1);
  var next = charAt(string, offset + 1);
  if ((exec(low, match) && !exec(hi, next)) || (exec(hi, match) && !exec(low, prev))) {
    return '\\u' + numberToString(charCodeAt(match, 0), 16);
  } return match;
};

if ($stringify) {
  // `JSON.stringify` method
  // https://tc39.es/ecma262/#sec-json.stringify
  $({ target: 'JSON', stat: true, arity: 3, forced: WRONG_SYMBOLS_CONVERSION || ILL_FORMED_UNICODE }, {
    // eslint-disable-next-line no-unused-vars -- required for `.length`
    stringify: function stringify(it, replacer, space) {
      var args = arraySlice(arguments);
      var result = apply(WRONG_SYMBOLS_CONVERSION ? stringifyWithSymbolsFix : $stringify, null, args);
      return ILL_FORMED_UNICODE && typeof result == 'string' ? replace(result, tester, fixIllFormed) : result;
    }
  });
}


/***/ }),

/***/ 4731:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var setToStringTag = __webpack_require__(687);

// JSON[@@toStringTag] property
// https://tc39.es/ecma262/#sec-json-@@tostringtag
setToStringTag(global.JSON, 'JSON', true);


/***/ }),

/***/ 5914:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var sign = __webpack_require__(7782);

// `Math.sign` method
// https://tc39.es/ecma262/#sec-math.sign
$({ target: 'Math', stat: true }, {
  sign: sign
});


/***/ }),

/***/ 479:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var setToStringTag = __webpack_require__(687);

// Math[@@toStringTag] property
// https://tc39.es/ecma262/#sec-math-@@tostringtag
setToStringTag(Math, 'Math', true);


/***/ }),

/***/ 2892:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var IS_PURE = __webpack_require__(6395);
var DESCRIPTORS = __webpack_require__(3724);
var global = __webpack_require__(4475);
var path = __webpack_require__(9167);
var uncurryThis = __webpack_require__(9504);
var isForced = __webpack_require__(2796);
var hasOwn = __webpack_require__(9297);
var inheritIfRequired = __webpack_require__(3167);
var isPrototypeOf = __webpack_require__(1625);
var isSymbol = __webpack_require__(757);
var toPrimitive = __webpack_require__(2777);
var fails = __webpack_require__(9039);
var getOwnPropertyNames = (__webpack_require__(8480).f);
var getOwnPropertyDescriptor = (__webpack_require__(7347).f);
var defineProperty = (__webpack_require__(4913).f);
var thisNumberValue = __webpack_require__(1240);
var trim = (__webpack_require__(3802).trim);

var NUMBER = 'Number';
var NativeNumber = global[NUMBER];
var PureNumberNamespace = path[NUMBER];
var NumberPrototype = NativeNumber.prototype;
var TypeError = global.TypeError;
var stringSlice = uncurryThis(''.slice);
var charCodeAt = uncurryThis(''.charCodeAt);

// `ToNumeric` abstract operation
// https://tc39.es/ecma262/#sec-tonumeric
var toNumeric = function (value) {
  var primValue = toPrimitive(value, 'number');
  return typeof primValue == 'bigint' ? primValue : toNumber(primValue);
};

// `ToNumber` abstract operation
// https://tc39.es/ecma262/#sec-tonumber
var toNumber = function (argument) {
  var it = toPrimitive(argument, 'number');
  var first, third, radix, maxCode, digits, length, index, code;
  if (isSymbol(it)) throw new TypeError('Cannot convert a Symbol value to a number');
  if (typeof it == 'string' && it.length > 2) {
    it = trim(it);
    first = charCodeAt(it, 0);
    if (first === 43 || first === 45) {
      third = charCodeAt(it, 2);
      if (third === 88 || third === 120) return NaN; // Number('+0x1') should be NaN, old V8 fix
    } else if (first === 48) {
      switch (charCodeAt(it, 1)) {
        // fast equal of /^0b[01]+$/i
        case 66:
        case 98:
          radix = 2;
          maxCode = 49;
          break;
        // fast equal of /^0o[0-7]+$/i
        case 79:
        case 111:
          radix = 8;
          maxCode = 55;
          break;
        default:
          return +it;
      }
      digits = stringSlice(it, 2);
      length = digits.length;
      for (index = 0; index < length; index++) {
        code = charCodeAt(digits, index);
        // parseInt parses a string to a first unavailable symbol
        // but ToNumber should return NaN if a string contains unavailable symbols
        if (code < 48 || code > maxCode) return NaN;
      } return parseInt(digits, radix);
    }
  } return +it;
};

var FORCED = isForced(NUMBER, !NativeNumber(' 0o1') || !NativeNumber('0b1') || NativeNumber('+0x1'));

var calledWithNew = function (dummy) {
  // includes check on 1..constructor(foo) case
  return isPrototypeOf(NumberPrototype, dummy) && fails(function () { thisNumberValue(dummy); });
};

// `Number` constructor
// https://tc39.es/ecma262/#sec-number-constructor
var NumberWrapper = function Number(value) {
  var n = arguments.length < 1 ? 0 : NativeNumber(toNumeric(value));
  return calledWithNew(this) ? inheritIfRequired(Object(n), this, NumberWrapper) : n;
};

NumberWrapper.prototype = NumberPrototype;
if (FORCED && !IS_PURE) NumberPrototype.constructor = NumberWrapper;

$({ global: true, constructor: true, wrap: true, forced: FORCED }, {
  Number: NumberWrapper
});

// Use `internal/copy-constructor-properties` helper in `core-js@4`
var copyConstructorProperties = function (target, source) {
  for (var keys = DESCRIPTORS ? getOwnPropertyNames(source) : (
    // ES3:
    'MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,' +
    // ES2015 (in case, if modules with ES2015 Number statics required before):
    'EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,' +
    // ESNext
    'fromString,range'
  ).split(','), j = 0, key; keys.length > j; j++) {
    if (hasOwn(source, key = keys[j]) && !hasOwn(target, key)) {
      defineProperty(target, key, getOwnPropertyDescriptor(source, key));
    }
  }
};

if (IS_PURE && PureNumberNamespace) copyConstructorProperties(path[NUMBER], PureNumberNamespace);
if (FORCED || IS_PURE) copyConstructorProperties(path[NUMBER], NativeNumber);


/***/ }),

/***/ 2811:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var FREEZING = __webpack_require__(2744);
var fails = __webpack_require__(9039);
var isObject = __webpack_require__(34);
var onFreeze = (__webpack_require__(3451).onFreeze);

// eslint-disable-next-line es/no-object-freeze -- safe
var $freeze = Object.freeze;
var FAILS_ON_PRIMITIVES = fails(function () { $freeze(1); });

// `Object.freeze` method
// https://tc39.es/ecma262/#sec-object.freeze
$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES, sham: !FREEZING }, {
  freeze: function freeze(it) {
    return $freeze && isObject(it) ? $freeze(onFreeze(it)) : it;
  }
});


/***/ }),

/***/ 3851:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var fails = __webpack_require__(9039);
var toIndexedObject = __webpack_require__(5397);
var nativeGetOwnPropertyDescriptor = (__webpack_require__(7347).f);
var DESCRIPTORS = __webpack_require__(3724);

var FORCED = !DESCRIPTORS || fails(function () { nativeGetOwnPropertyDescriptor(1); });

// `Object.getOwnPropertyDescriptor` method
// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
$({ target: 'Object', stat: true, forced: FORCED, sham: !DESCRIPTORS }, {
  getOwnPropertyDescriptor: function getOwnPropertyDescriptor(it, key) {
    return nativeGetOwnPropertyDescriptor(toIndexedObject(it), key);
  }
});


/***/ }),

/***/ 9773:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var NATIVE_SYMBOL = __webpack_require__(4495);
var fails = __webpack_require__(9039);
var getOwnPropertySymbolsModule = __webpack_require__(3717);
var toObject = __webpack_require__(8981);

// V8 ~ Chrome 38 and 39 `Object.getOwnPropertySymbols` fails on primitives
// https://bugs.chromium.org/p/v8/issues/detail?id=3443
var FORCED = !NATIVE_SYMBOL || fails(function () { getOwnPropertySymbolsModule.f(1); });

// `Object.getOwnPropertySymbols` method
// https://tc39.es/ecma262/#sec-object.getownpropertysymbols
$({ target: 'Object', stat: true, forced: FORCED }, {
  getOwnPropertySymbols: function getOwnPropertySymbols(it) {
    var $getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
    return $getOwnPropertySymbols ? $getOwnPropertySymbols(toObject(it)) : [];
  }
});


/***/ }),

/***/ 875:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var fails = __webpack_require__(9039);
var toObject = __webpack_require__(8981);
var nativeGetPrototypeOf = __webpack_require__(2787);
var CORRECT_PROTOTYPE_GETTER = __webpack_require__(2211);

var FAILS_ON_PRIMITIVES = fails(function () { nativeGetPrototypeOf(1); });

// `Object.getPrototypeOf` method
// https://tc39.es/ecma262/#sec-object.getprototypeof
$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES, sham: !CORRECT_PROTOTYPE_GETTER }, {
  getPrototypeOf: function getPrototypeOf(it) {
    return nativeGetPrototypeOf(toObject(it));
  }
});



/***/ }),

/***/ 9432:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var toObject = __webpack_require__(8981);
var nativeKeys = __webpack_require__(1072);
var fails = __webpack_require__(9039);

var FAILS_ON_PRIMITIVES = fails(function () { nativeKeys(1); });

// `Object.keys` method
// https://tc39.es/ecma262/#sec-object.keys
$({ target: 'Object', stat: true, forced: FAILS_ON_PRIMITIVES }, {
  keys: function keys(it) {
    return nativeKeys(toObject(it));
  }
});


/***/ }),

/***/ 287:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var setPrototypeOf = __webpack_require__(2967);

// `Object.setPrototypeOf` method
// https://tc39.es/ecma262/#sec-object.setprototypeof
$({ target: 'Object', stat: true }, {
  setPrototypeOf: setPrototypeOf
});


/***/ }),

/***/ 6099:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var TO_STRING_TAG_SUPPORT = __webpack_require__(2140);
var defineBuiltIn = __webpack_require__(6840);
var toString = __webpack_require__(3179);

// `Object.prototype.toString` method
// https://tc39.es/ecma262/#sec-object.prototype.tostring
if (!TO_STRING_TAG_SUPPORT) {
  defineBuiltIn(Object.prototype, 'toString', toString, { unsafe: true });
}


/***/ }),

/***/ 6499:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var call = __webpack_require__(9565);
var aCallable = __webpack_require__(9306);
var newPromiseCapabilityModule = __webpack_require__(6043);
var perform = __webpack_require__(1103);
var iterate = __webpack_require__(2652);
var PROMISE_STATICS_INCORRECT_ITERATION = __webpack_require__(537);

// `Promise.all` method
// https://tc39.es/ecma262/#sec-promise.all
$({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
  all: function all(iterable) {
    var C = this;
    var capability = newPromiseCapabilityModule.f(C);
    var resolve = capability.resolve;
    var reject = capability.reject;
    var result = perform(function () {
      var $promiseResolve = aCallable(C.resolve);
      var values = [];
      var counter = 0;
      var remaining = 1;
      iterate(iterable, function (promise) {
        var index = counter++;
        var alreadyCalled = false;
        remaining++;
        call($promiseResolve, C, promise).then(function (value) {
          if (alreadyCalled) return;
          alreadyCalled = true;
          values[index] = value;
          --remaining || resolve(values);
        }, reject);
      });
      --remaining || resolve(values);
    });
    if (result.error) reject(result.value);
    return capability.promise;
  }
});


/***/ }),

/***/ 2003:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var IS_PURE = __webpack_require__(6395);
var FORCED_PROMISE_CONSTRUCTOR = (__webpack_require__(916).CONSTRUCTOR);
var NativePromiseConstructor = __webpack_require__(550);
var getBuiltIn = __webpack_require__(7751);
var isCallable = __webpack_require__(4901);
var defineBuiltIn = __webpack_require__(6840);

var NativePromisePrototype = NativePromiseConstructor && NativePromiseConstructor.prototype;

// `Promise.prototype.catch` method
// https://tc39.es/ecma262/#sec-promise.prototype.catch
$({ target: 'Promise', proto: true, forced: FORCED_PROMISE_CONSTRUCTOR, real: true }, {
  'catch': function (onRejected) {
    return this.then(undefined, onRejected);
  }
});

// makes sure that native promise-based APIs `Promise#catch` properly works with patched `Promise#then`
if (!IS_PURE && isCallable(NativePromiseConstructor)) {
  var method = getBuiltIn('Promise').prototype['catch'];
  if (NativePromisePrototype['catch'] !== method) {
    defineBuiltIn(NativePromisePrototype, 'catch', method, { unsafe: true });
  }
}


/***/ }),

/***/ 436:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var IS_PURE = __webpack_require__(6395);
var IS_NODE = __webpack_require__(9088);
var global = __webpack_require__(4475);
var call = __webpack_require__(9565);
var defineBuiltIn = __webpack_require__(6840);
var setPrototypeOf = __webpack_require__(2967);
var setToStringTag = __webpack_require__(687);
var setSpecies = __webpack_require__(7633);
var aCallable = __webpack_require__(9306);
var isCallable = __webpack_require__(4901);
var isObject = __webpack_require__(34);
var anInstance = __webpack_require__(679);
var speciesConstructor = __webpack_require__(2293);
var task = (__webpack_require__(9225).set);
var microtask = __webpack_require__(1955);
var hostReportErrors = __webpack_require__(3138);
var perform = __webpack_require__(1103);
var Queue = __webpack_require__(8265);
var InternalStateModule = __webpack_require__(1181);
var NativePromiseConstructor = __webpack_require__(550);
var PromiseConstructorDetection = __webpack_require__(916);
var newPromiseCapabilityModule = __webpack_require__(6043);

var PROMISE = 'Promise';
var FORCED_PROMISE_CONSTRUCTOR = PromiseConstructorDetection.CONSTRUCTOR;
var NATIVE_PROMISE_REJECTION_EVENT = PromiseConstructorDetection.REJECTION_EVENT;
var NATIVE_PROMISE_SUBCLASSING = PromiseConstructorDetection.SUBCLASSING;
var getInternalPromiseState = InternalStateModule.getterFor(PROMISE);
var setInternalState = InternalStateModule.set;
var NativePromisePrototype = NativePromiseConstructor && NativePromiseConstructor.prototype;
var PromiseConstructor = NativePromiseConstructor;
var PromisePrototype = NativePromisePrototype;
var TypeError = global.TypeError;
var document = global.document;
var process = global.process;
var newPromiseCapability = newPromiseCapabilityModule.f;
var newGenericPromiseCapability = newPromiseCapability;

var DISPATCH_EVENT = !!(document && document.createEvent && global.dispatchEvent);
var UNHANDLED_REJECTION = 'unhandledrejection';
var REJECTION_HANDLED = 'rejectionhandled';
var PENDING = 0;
var FULFILLED = 1;
var REJECTED = 2;
var HANDLED = 1;
var UNHANDLED = 2;

var Internal, OwnPromiseCapability, PromiseWrapper, nativeThen;

// helpers
var isThenable = function (it) {
  var then;
  return isObject(it) && isCallable(then = it.then) ? then : false;
};

var callReaction = function (reaction, state) {
  var value = state.value;
  var ok = state.state === FULFILLED;
  var handler = ok ? reaction.ok : reaction.fail;
  var resolve = reaction.resolve;
  var reject = reaction.reject;
  var domain = reaction.domain;
  var result, then, exited;
  try {
    if (handler) {
      if (!ok) {
        if (state.rejection === UNHANDLED) onHandleUnhandled(state);
        state.rejection = HANDLED;
      }
      if (handler === true) result = value;
      else {
        if (domain) domain.enter();
        result = handler(value); // can throw
        if (domain) {
          domain.exit();
          exited = true;
        }
      }
      if (result === reaction.promise) {
        reject(new TypeError('Promise-chain cycle'));
      } else if (then = isThenable(result)) {
        call(then, result, resolve, reject);
      } else resolve(result);
    } else reject(value);
  } catch (error) {
    if (domain && !exited) domain.exit();
    reject(error);
  }
};

var notify = function (state, isReject) {
  if (state.notified) return;
  state.notified = true;
  microtask(function () {
    var reactions = state.reactions;
    var reaction;
    while (reaction = reactions.get()) {
      callReaction(reaction, state);
    }
    state.notified = false;
    if (isReject && !state.rejection) onUnhandled(state);
  });
};

var dispatchEvent = function (name, promise, reason) {
  var event, handler;
  if (DISPATCH_EVENT) {
    event = document.createEvent('Event');
    event.promise = promise;
    event.reason = reason;
    event.initEvent(name, false, true);
    global.dispatchEvent(event);
  } else event = { promise: promise, reason: reason };
  if (!NATIVE_PROMISE_REJECTION_EVENT && (handler = global['on' + name])) handler(event);
  else if (name === UNHANDLED_REJECTION) hostReportErrors('Unhandled promise rejection', reason);
};

var onUnhandled = function (state) {
  call(task, global, function () {
    var promise = state.facade;
    var value = state.value;
    var IS_UNHANDLED = isUnhandled(state);
    var result;
    if (IS_UNHANDLED) {
      result = perform(function () {
        if (IS_NODE) {
          process.emit('unhandledRejection', value, promise);
        } else dispatchEvent(UNHANDLED_REJECTION, promise, value);
      });
      // Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should
      state.rejection = IS_NODE || isUnhandled(state) ? UNHANDLED : HANDLED;
      if (result.error) throw result.value;
    }
  });
};

var isUnhandled = function (state) {
  return state.rejection !== HANDLED && !state.parent;
};

var onHandleUnhandled = function (state) {
  call(task, global, function () {
    var promise = state.facade;
    if (IS_NODE) {
      process.emit('rejectionHandled', promise);
    } else dispatchEvent(REJECTION_HANDLED, promise, state.value);
  });
};

var bind = function (fn, state, unwrap) {
  return function (value) {
    fn(state, value, unwrap);
  };
};

var internalReject = function (state, value, unwrap) {
  if (state.done) return;
  state.done = true;
  if (unwrap) state = unwrap;
  state.value = value;
  state.state = REJECTED;
  notify(state, true);
};

var internalResolve = function (state, value, unwrap) {
  if (state.done) return;
  state.done = true;
  if (unwrap) state = unwrap;
  try {
    if (state.facade === value) throw new TypeError("Promise can't be resolved itself");
    var then = isThenable(value);
    if (then) {
      microtask(function () {
        var wrapper = { done: false };
        try {
          call(then, value,
            bind(internalResolve, wrapper, state),
            bind(internalReject, wrapper, state)
          );
        } catch (error) {
          internalReject(wrapper, error, state);
        }
      });
    } else {
      state.value = value;
      state.state = FULFILLED;
      notify(state, false);
    }
  } catch (error) {
    internalReject({ done: false }, error, state);
  }
};

// constructor polyfill
if (FORCED_PROMISE_CONSTRUCTOR) {
  // 25.4.3.1 Promise(executor)
  PromiseConstructor = function Promise(executor) {
    anInstance(this, PromisePrototype);
    aCallable(executor);
    call(Internal, this);
    var state = getInternalPromiseState(this);
    try {
      executor(bind(internalResolve, state), bind(internalReject, state));
    } catch (error) {
      internalReject(state, error);
    }
  };

  PromisePrototype = PromiseConstructor.prototype;

  // eslint-disable-next-line no-unused-vars -- required for `.length`
  Internal = function Promise(executor) {
    setInternalState(this, {
      type: PROMISE,
      done: false,
      notified: false,
      parent: false,
      reactions: new Queue(),
      rejection: false,
      state: PENDING,
      value: undefined
    });
  };

  // `Promise.prototype.then` method
  // https://tc39.es/ecma262/#sec-promise.prototype.then
  Internal.prototype = defineBuiltIn(PromisePrototype, 'then', function then(onFulfilled, onRejected) {
    var state = getInternalPromiseState(this);
    var reaction = newPromiseCapability(speciesConstructor(this, PromiseConstructor));
    state.parent = true;
    reaction.ok = isCallable(onFulfilled) ? onFulfilled : true;
    reaction.fail = isCallable(onRejected) && onRejected;
    reaction.domain = IS_NODE ? process.domain : undefined;
    if (state.state === PENDING) state.reactions.add(reaction);
    else microtask(function () {
      callReaction(reaction, state);
    });
    return reaction.promise;
  });

  OwnPromiseCapability = function () {
    var promise = new Internal();
    var state = getInternalPromiseState(promise);
    this.promise = promise;
    this.resolve = bind(internalResolve, state);
    this.reject = bind(internalReject, state);
  };

  newPromiseCapabilityModule.f = newPromiseCapability = function (C) {
    return C === PromiseConstructor || C === PromiseWrapper
      ? new OwnPromiseCapability(C)
      : newGenericPromiseCapability(C);
  };

  if (!IS_PURE && isCallable(NativePromiseConstructor) && NativePromisePrototype !== Object.prototype) {
    nativeThen = NativePromisePrototype.then;

    if (!NATIVE_PROMISE_SUBCLASSING) {
      // make `Promise#then` return a polyfilled `Promise` for native promise-based APIs
      defineBuiltIn(NativePromisePrototype, 'then', function then(onFulfilled, onRejected) {
        var that = this;
        return new PromiseConstructor(function (resolve, reject) {
          call(nativeThen, that, resolve, reject);
        }).then(onFulfilled, onRejected);
      // https://github.com/zloirock/core-js/issues/640
      }, { unsafe: true });
    }

    // make `.constructor === Promise` work for native promise-based APIs
    try {
      delete NativePromisePrototype.constructor;
    } catch (error) { /* empty */ }

    // make `instanceof Promise` work for native promise-based APIs
    if (setPrototypeOf) {
      setPrototypeOf(NativePromisePrototype, PromisePrototype);
    }
  }
}

$({ global: true, constructor: true, wrap: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
  Promise: PromiseConstructor
});

setToStringTag(PromiseConstructor, PROMISE, false, true);
setSpecies(PROMISE);


/***/ }),

/***/ 3362:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove this module from `core-js@4` since it's split to modules listed below
__webpack_require__(436);
__webpack_require__(6499);
__webpack_require__(2003);
__webpack_require__(7743);
__webpack_require__(1481);
__webpack_require__(280);


/***/ }),

/***/ 7743:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var call = __webpack_require__(9565);
var aCallable = __webpack_require__(9306);
var newPromiseCapabilityModule = __webpack_require__(6043);
var perform = __webpack_require__(1103);
var iterate = __webpack_require__(2652);
var PROMISE_STATICS_INCORRECT_ITERATION = __webpack_require__(537);

// `Promise.race` method
// https://tc39.es/ecma262/#sec-promise.race
$({ target: 'Promise', stat: true, forced: PROMISE_STATICS_INCORRECT_ITERATION }, {
  race: function race(iterable) {
    var C = this;
    var capability = newPromiseCapabilityModule.f(C);
    var reject = capability.reject;
    var result = perform(function () {
      var $promiseResolve = aCallable(C.resolve);
      iterate(iterable, function (promise) {
        call($promiseResolve, C, promise).then(capability.resolve, reject);
      });
    });
    if (result.error) reject(result.value);
    return capability.promise;
  }
});


/***/ }),

/***/ 1481:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var newPromiseCapabilityModule = __webpack_require__(6043);
var FORCED_PROMISE_CONSTRUCTOR = (__webpack_require__(916).CONSTRUCTOR);

// `Promise.reject` method
// https://tc39.es/ecma262/#sec-promise.reject
$({ target: 'Promise', stat: true, forced: FORCED_PROMISE_CONSTRUCTOR }, {
  reject: function reject(r) {
    var capability = newPromiseCapabilityModule.f(this);
    var capabilityReject = capability.reject;
    capabilityReject(r);
    return capability.promise;
  }
});


/***/ }),

/***/ 280:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var getBuiltIn = __webpack_require__(7751);
var IS_PURE = __webpack_require__(6395);
var NativePromiseConstructor = __webpack_require__(550);
var FORCED_PROMISE_CONSTRUCTOR = (__webpack_require__(916).CONSTRUCTOR);
var promiseResolve = __webpack_require__(3438);

var PromiseConstructorWrapper = getBuiltIn('Promise');
var CHECK_WRAPPER = IS_PURE && !FORCED_PROMISE_CONSTRUCTOR;

// `Promise.resolve` method
// https://tc39.es/ecma262/#sec-promise.resolve
$({ target: 'Promise', stat: true, forced: IS_PURE || FORCED_PROMISE_CONSTRUCTOR }, {
  resolve: function resolve(x) {
    return promiseResolve(CHECK_WRAPPER && this === PromiseConstructorWrapper ? NativePromiseConstructor : this, x);
  }
});


/***/ }),

/***/ 825:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var getBuiltIn = __webpack_require__(7751);
var apply = __webpack_require__(8745);
var bind = __webpack_require__(566);
var aConstructor = __webpack_require__(5548);
var anObject = __webpack_require__(8551);
var isObject = __webpack_require__(34);
var create = __webpack_require__(2360);
var fails = __webpack_require__(9039);

var nativeConstruct = getBuiltIn('Reflect', 'construct');
var ObjectPrototype = Object.prototype;
var push = [].push;

// `Reflect.construct` method
// https://tc39.es/ecma262/#sec-reflect.construct
// MS Edge supports only 2 arguments and argumentsList argument is optional
// FF Nightly sets third argument as `new.target`, but does not create `this` from it
var NEW_TARGET_BUG = fails(function () {
  function F() { /* empty */ }
  return !(nativeConstruct(function () { /* empty */ }, [], F) instanceof F);
});

var ARGS_BUG = !fails(function () {
  nativeConstruct(function () { /* empty */ });
});

var FORCED = NEW_TARGET_BUG || ARGS_BUG;

$({ target: 'Reflect', stat: true, forced: FORCED, sham: FORCED }, {
  construct: function construct(Target, args /* , newTarget */) {
    aConstructor(Target);
    anObject(args);
    var newTarget = arguments.length < 3 ? Target : aConstructor(arguments[2]);
    if (ARGS_BUG && !NEW_TARGET_BUG) return nativeConstruct(Target, args, newTarget);
    if (Target === newTarget) {
      // w/o altered newTarget, optimization for 0-4 arguments
      switch (args.length) {
        case 0: return new Target();
        case 1: return new Target(args[0]);
        case 2: return new Target(args[0], args[1]);
        case 3: return new Target(args[0], args[1], args[2]);
        case 4: return new Target(args[0], args[1], args[2], args[3]);
      }
      // w/o altered newTarget, lot of arguments case
      var $args = [null];
      apply(push, $args, args);
      return new (apply(bind, Target, $args))();
    }
    // with altered newTarget, not support built-in constructors
    var proto = newTarget.prototype;
    var instance = create(isObject(proto) ? proto : ObjectPrototype);
    var result = apply(Target, instance, args);
    return isObject(result) ? result : instance;
  }
});


/***/ }),

/***/ 888:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var call = __webpack_require__(9565);
var isObject = __webpack_require__(34);
var anObject = __webpack_require__(8551);
var isDataDescriptor = __webpack_require__(6575);
var getOwnPropertyDescriptorModule = __webpack_require__(7347);
var getPrototypeOf = __webpack_require__(2787);

// `Reflect.get` method
// https://tc39.es/ecma262/#sec-reflect.get
function get(target, propertyKey /* , receiver */) {
  var receiver = arguments.length < 3 ? target : arguments[2];
  var descriptor, prototype;
  if (anObject(target) === receiver) return target[propertyKey];
  descriptor = getOwnPropertyDescriptorModule.f(target, propertyKey);
  if (descriptor) return isDataDescriptor(descriptor)
    ? descriptor.value
    : descriptor.get === undefined ? undefined : call(descriptor.get, receiver);
  if (isObject(prototype = getPrototypeOf(target))) return get(prototype, propertyKey, receiver);
}

$({ target: 'Reflect', stat: true }, {
  get: get
});


/***/ }),

/***/ 5472:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var global = __webpack_require__(4475);
var setToStringTag = __webpack_require__(687);

$({ global: true }, { Reflect: {} });

// Reflect[@@toStringTag] property
// https://tc39.es/ecma262/#sec-reflect-@@tostringtag
setToStringTag(global.Reflect, 'Reflect', true);


/***/ }),

/***/ 7495:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var exec = __webpack_require__(7323);

// `RegExp.prototype.exec` method
// https://tc39.es/ecma262/#sec-regexp.prototype.exec
$({ target: 'RegExp', proto: true, forced: /./.exec !== exec }, {
  exec: exec
});


/***/ }),

/***/ 906:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove from `core-js@4` since it's moved to entry points
__webpack_require__(7495);
var $ = __webpack_require__(6518);
var call = __webpack_require__(9565);
var isCallable = __webpack_require__(4901);
var anObject = __webpack_require__(8551);
var toString = __webpack_require__(655);

var DELEGATES_TO_EXEC = function () {
  var execCalled = false;
  var re = /[ac]/;
  re.exec = function () {
    execCalled = true;
    return /./.exec.apply(this, arguments);
  };
  return re.test('abc') === true && execCalled;
}();

var nativeTest = /./.test;

// `RegExp.prototype.test` method
// https://tc39.es/ecma262/#sec-regexp.prototype.test
$({ target: 'RegExp', proto: true, forced: !DELEGATES_TO_EXEC }, {
  test: function (S) {
    var R = anObject(this);
    var string = toString(S);
    var exec = R.exec;
    if (!isCallable(exec)) return call(nativeTest, R, string);
    var result = call(exec, R, string);
    if (result === null) return false;
    anObject(result);
    return true;
  }
});


/***/ }),

/***/ 8781:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var PROPER_FUNCTION_NAME = (__webpack_require__(350).PROPER);
var defineBuiltIn = __webpack_require__(6840);
var anObject = __webpack_require__(8551);
var $toString = __webpack_require__(655);
var fails = __webpack_require__(9039);
var getRegExpFlags = __webpack_require__(1034);

var TO_STRING = 'toString';
var RegExpPrototype = RegExp.prototype;
var nativeToString = RegExpPrototype[TO_STRING];

var NOT_GENERIC = fails(function () { return nativeToString.call({ source: 'a', flags: 'b' }) !== '/a/b'; });
// FF44- RegExp#toString has a wrong name
var INCORRECT_NAME = PROPER_FUNCTION_NAME && nativeToString.name !== TO_STRING;

// `RegExp.prototype.toString` method
// https://tc39.es/ecma262/#sec-regexp.prototype.tostring
if (NOT_GENERIC || INCORRECT_NAME) {
  defineBuiltIn(RegExpPrototype, TO_STRING, function toString() {
    var R = anObject(this);
    var pattern = $toString(R.source);
    var flags = $toString(getRegExpFlags(R));
    return '/' + pattern + '/' + flags;
  }, { unsafe: true });
}


/***/ }),

/***/ 7357:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var uncurryThis = __webpack_require__(9504);
var requireObjectCoercible = __webpack_require__(7750);
var toIntegerOrInfinity = __webpack_require__(1291);
var toString = __webpack_require__(655);
var fails = __webpack_require__(9039);

var charAt = uncurryThis(''.charAt);

var FORCED = fails(function () {
  // eslint-disable-next-line es/no-array-string-prototype-at -- safe
  return '𠮷'.at(-2) !== '\uD842';
});

// `String.prototype.at` method
// https://tc39.es/ecma262/#sec-string.prototype.at
$({ target: 'String', proto: true, forced: FORCED }, {
  at: function at(index) {
    var S = toString(requireObjectCoercible(this));
    var len = S.length;
    var relativeIndex = toIntegerOrInfinity(index);
    var k = relativeIndex >= 0 ? relativeIndex : len + relativeIndex;
    return (k < 0 || k >= len) ? undefined : charAt(S, k);
  }
});


/***/ }),

/***/ 9449:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var uncurryThis = __webpack_require__(7476);
var getOwnPropertyDescriptor = (__webpack_require__(7347).f);
var toLength = __webpack_require__(8014);
var toString = __webpack_require__(655);
var notARegExp = __webpack_require__(5749);
var requireObjectCoercible = __webpack_require__(7750);
var correctIsRegExpLogic = __webpack_require__(1436);
var IS_PURE = __webpack_require__(6395);

var slice = uncurryThis(''.slice);
var min = Math.min;

var CORRECT_IS_REGEXP_LOGIC = correctIsRegExpLogic('endsWith');
// https://github.com/zloirock/core-js/pull/702
var MDN_POLYFILL_BUG = !IS_PURE && !CORRECT_IS_REGEXP_LOGIC && !!function () {
  var descriptor = getOwnPropertyDescriptor(String.prototype, 'endsWith');
  return descriptor && !descriptor.writable;
}();

// `String.prototype.endsWith` method
// https://tc39.es/ecma262/#sec-string.prototype.endswith
$({ target: 'String', proto: true, forced: !MDN_POLYFILL_BUG && !CORRECT_IS_REGEXP_LOGIC }, {
  endsWith: function endsWith(searchString /* , endPosition = @length */) {
    var that = toString(requireObjectCoercible(this));
    notARegExp(searchString);
    var endPosition = arguments.length > 1 ? arguments[1] : undefined;
    var len = that.length;
    var end = endPosition === undefined ? len : min(toLength(endPosition), len);
    var search = toString(searchString);
    return slice(that, end - search.length, end) === search;
  }
});


/***/ }),

/***/ 7764:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var charAt = (__webpack_require__(8183).charAt);
var toString = __webpack_require__(655);
var InternalStateModule = __webpack_require__(1181);
var defineIterator = __webpack_require__(1088);
var createIterResultObject = __webpack_require__(2529);

var STRING_ITERATOR = 'String Iterator';
var setInternalState = InternalStateModule.set;
var getInternalState = InternalStateModule.getterFor(STRING_ITERATOR);

// `String.prototype[@@iterator]` method
// https://tc39.es/ecma262/#sec-string.prototype-@@iterator
defineIterator(String, 'String', function (iterated) {
  setInternalState(this, {
    type: STRING_ITERATOR,
    string: toString(iterated),
    index: 0
  });
// `%StringIteratorPrototype%.next` method
// https://tc39.es/ecma262/#sec-%stringiteratorprototype%.next
}, function next() {
  var state = getInternalState(this);
  var string = state.string;
  var index = state.index;
  var point;
  if (index >= string.length) return createIterResultObject(undefined, true);
  point = charAt(string, index);
  state.index += point.length;
  return createIterResultObject(point, false);
});


/***/ }),

/***/ 5440:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var apply = __webpack_require__(8745);
var call = __webpack_require__(9565);
var uncurryThis = __webpack_require__(9504);
var fixRegExpWellKnownSymbolLogic = __webpack_require__(9228);
var fails = __webpack_require__(9039);
var anObject = __webpack_require__(8551);
var isCallable = __webpack_require__(4901);
var isNullOrUndefined = __webpack_require__(4117);
var toIntegerOrInfinity = __webpack_require__(1291);
var toLength = __webpack_require__(8014);
var toString = __webpack_require__(655);
var requireObjectCoercible = __webpack_require__(7750);
var advanceStringIndex = __webpack_require__(7829);
var getMethod = __webpack_require__(5966);
var getSubstitution = __webpack_require__(2478);
var regExpExec = __webpack_require__(6682);
var wellKnownSymbol = __webpack_require__(8227);

var REPLACE = wellKnownSymbol('replace');
var max = Math.max;
var min = Math.min;
var concat = uncurryThis([].concat);
var push = uncurryThis([].push);
var stringIndexOf = uncurryThis(''.indexOf);
var stringSlice = uncurryThis(''.slice);

var maybeToString = function (it) {
  return it === undefined ? it : String(it);
};

// IE <= 11 replaces $0 with the whole match, as if it was $&
// https://stackoverflow.com/questions/6024666/getting-ie-to-replace-a-regex-with-the-literal-string-0
var REPLACE_KEEPS_$0 = (function () {
  // eslint-disable-next-line regexp/prefer-escape-replacement-dollar-char -- required for testing
  return 'a'.replace(/./, '$0') === '$0';
})();

// Safari <= 13.0.3(?) substitutes nth capture where n>m with an empty string
var REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = (function () {
  if (/./[REPLACE]) {
    return /./[REPLACE]('a', '$0') === '';
  }
  return false;
})();

var REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {
  var re = /./;
  re.exec = function () {
    var result = [];
    result.groups = { a: '7' };
    return result;
  };
  // eslint-disable-next-line regexp/no-useless-dollar-replacements -- false positive
  return ''.replace(re, '$<a>') !== '7';
});

// @@replace logic
fixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNative) {
  var UNSAFE_SUBSTITUTE = REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE ? '$' : '$0';

  return [
    // `String.prototype.replace` method
    // https://tc39.es/ecma262/#sec-string.prototype.replace
    function replace(searchValue, replaceValue) {
      var O = requireObjectCoercible(this);
      var replacer = isNullOrUndefined(searchValue) ? undefined : getMethod(searchValue, REPLACE);
      return replacer
        ? call(replacer, searchValue, O, replaceValue)
        : call(nativeReplace, toString(O), searchValue, replaceValue);
    },
    // `RegExp.prototype[@@replace]` method
    // https://tc39.es/ecma262/#sec-regexp.prototype-@@replace
    function (string, replaceValue) {
      var rx = anObject(this);
      var S = toString(string);

      if (
        typeof replaceValue == 'string' &&
        stringIndexOf(replaceValue, UNSAFE_SUBSTITUTE) === -1 &&
        stringIndexOf(replaceValue, '$<') === -1
      ) {
        var res = maybeCallNative(nativeReplace, rx, S, replaceValue);
        if (res.done) return res.value;
      }

      var functionalReplace = isCallable(replaceValue);
      if (!functionalReplace) replaceValue = toString(replaceValue);

      var global = rx.global;
      var fullUnicode;
      if (global) {
        fullUnicode = rx.unicode;
        rx.lastIndex = 0;
      }

      var results = [];
      var result;
      while (true) {
        result = regExpExec(rx, S);
        if (result === null) break;

        push(results, result);
        if (!global) break;

        var matchStr = toString(result[0]);
        if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);
      }

      var accumulatedResult = '';
      var nextSourcePosition = 0;
      for (var i = 0; i < results.length; i++) {
        result = results[i];

        var matched = toString(result[0]);
        var position = max(min(toIntegerOrInfinity(result.index), S.length), 0);
        var captures = [];
        var replacement;
        // NOTE: This is equivalent to
        //   captures = result.slice(1).map(maybeToString)
        // but for some reason `nativeSlice.call(result, 1, result.length)` (called in
        // the slice polyfill when slicing native arrays) "doesn't work" in safari 9 and
        // causes a crash (https://pastebin.com/N21QzeQA) when trying to debug it.
        for (var j = 1; j < result.length; j++) push(captures, maybeToString(result[j]));
        var namedCaptures = result.groups;
        if (functionalReplace) {
          var replacerArgs = concat([matched], captures, position, S);
          if (namedCaptures !== undefined) push(replacerArgs, namedCaptures);
          replacement = toString(apply(replaceValue, undefined, replacerArgs));
        } else {
          replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);
        }
        if (position >= nextSourcePosition) {
          accumulatedResult += stringSlice(S, nextSourcePosition, position) + replacement;
          nextSourcePosition = position + matched.length;
        }
      }

      return accumulatedResult + stringSlice(S, nextSourcePosition);
    }
  ];
}, !REPLACE_SUPPORTS_NAMED_GROUPS || !REPLACE_KEEPS_$0 || REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE);


/***/ }),

/***/ 6412:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var defineWellKnownSymbol = __webpack_require__(511);

// `Symbol.asyncIterator` well-known symbol
// https://tc39.es/ecma262/#sec-symbol.asynciterator
defineWellKnownSymbol('asyncIterator');


/***/ }),

/***/ 6761:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var global = __webpack_require__(4475);
var call = __webpack_require__(9565);
var uncurryThis = __webpack_require__(9504);
var IS_PURE = __webpack_require__(6395);
var DESCRIPTORS = __webpack_require__(3724);
var NATIVE_SYMBOL = __webpack_require__(4495);
var fails = __webpack_require__(9039);
var hasOwn = __webpack_require__(9297);
var isPrototypeOf = __webpack_require__(1625);
var anObject = __webpack_require__(8551);
var toIndexedObject = __webpack_require__(5397);
var toPropertyKey = __webpack_require__(6969);
var $toString = __webpack_require__(655);
var createPropertyDescriptor = __webpack_require__(6980);
var nativeObjectCreate = __webpack_require__(2360);
var objectKeys = __webpack_require__(1072);
var getOwnPropertyNamesModule = __webpack_require__(8480);
var getOwnPropertyNamesExternal = __webpack_require__(298);
var getOwnPropertySymbolsModule = __webpack_require__(3717);
var getOwnPropertyDescriptorModule = __webpack_require__(7347);
var definePropertyModule = __webpack_require__(4913);
var definePropertiesModule = __webpack_require__(6801);
var propertyIsEnumerableModule = __webpack_require__(8773);
var defineBuiltIn = __webpack_require__(6840);
var defineBuiltInAccessor = __webpack_require__(2106);
var shared = __webpack_require__(5745);
var sharedKey = __webpack_require__(6119);
var hiddenKeys = __webpack_require__(421);
var uid = __webpack_require__(3392);
var wellKnownSymbol = __webpack_require__(8227);
var wrappedWellKnownSymbolModule = __webpack_require__(1951);
var defineWellKnownSymbol = __webpack_require__(511);
var defineSymbolToPrimitive = __webpack_require__(8242);
var setToStringTag = __webpack_require__(687);
var InternalStateModule = __webpack_require__(1181);
var $forEach = (__webpack_require__(9213).forEach);

var HIDDEN = sharedKey('hidden');
var SYMBOL = 'Symbol';
var PROTOTYPE = 'prototype';

var setInternalState = InternalStateModule.set;
var getInternalState = InternalStateModule.getterFor(SYMBOL);

var ObjectPrototype = Object[PROTOTYPE];
var $Symbol = global.Symbol;
var SymbolPrototype = $Symbol && $Symbol[PROTOTYPE];
var RangeError = global.RangeError;
var TypeError = global.TypeError;
var QObject = global.QObject;
var nativeGetOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
var nativeDefineProperty = definePropertyModule.f;
var nativeGetOwnPropertyNames = getOwnPropertyNamesExternal.f;
var nativePropertyIsEnumerable = propertyIsEnumerableModule.f;
var push = uncurryThis([].push);

var AllSymbols = shared('symbols');
var ObjectPrototypeSymbols = shared('op-symbols');
var WellKnownSymbolsStore = shared('wks');

// Don't use setters in Qt Script, https://github.com/zloirock/core-js/issues/173
var USE_SETTER = !QObject || !QObject[PROTOTYPE] || !QObject[PROTOTYPE].findChild;

// fallback for old Android, https://code.google.com/p/v8/issues/detail?id=687
var fallbackDefineProperty = function (O, P, Attributes) {
  var ObjectPrototypeDescriptor = nativeGetOwnPropertyDescriptor(ObjectPrototype, P);
  if (ObjectPrototypeDescriptor) delete ObjectPrototype[P];
  nativeDefineProperty(O, P, Attributes);
  if (ObjectPrototypeDescriptor && O !== ObjectPrototype) {
    nativeDefineProperty(ObjectPrototype, P, ObjectPrototypeDescriptor);
  }
};

var setSymbolDescriptor = DESCRIPTORS && fails(function () {
  return nativeObjectCreate(nativeDefineProperty({}, 'a', {
    get: function () { return nativeDefineProperty(this, 'a', { value: 7 }).a; }
  })).a !== 7;
}) ? fallbackDefineProperty : nativeDefineProperty;

var wrap = function (tag, description) {
  var symbol = AllSymbols[tag] = nativeObjectCreate(SymbolPrototype);
  setInternalState(symbol, {
    type: SYMBOL,
    tag: tag,
    description: description
  });
  if (!DESCRIPTORS) symbol.description = description;
  return symbol;
};

var $defineProperty = function defineProperty(O, P, Attributes) {
  if (O === ObjectPrototype) $defineProperty(ObjectPrototypeSymbols, P, Attributes);
  anObject(O);
  var key = toPropertyKey(P);
  anObject(Attributes);
  if (hasOwn(AllSymbols, key)) {
    if (!Attributes.enumerable) {
      if (!hasOwn(O, HIDDEN)) nativeDefineProperty(O, HIDDEN, createPropertyDescriptor(1, nativeObjectCreate(null)));
      O[HIDDEN][key] = true;
    } else {
      if (hasOwn(O, HIDDEN) && O[HIDDEN][key]) O[HIDDEN][key] = false;
      Attributes = nativeObjectCreate(Attributes, { enumerable: createPropertyDescriptor(0, false) });
    } return setSymbolDescriptor(O, key, Attributes);
  } return nativeDefineProperty(O, key, Attributes);
};

var $defineProperties = function defineProperties(O, Properties) {
  anObject(O);
  var properties = toIndexedObject(Properties);
  var keys = objectKeys(properties).concat($getOwnPropertySymbols(properties));
  $forEach(keys, function (key) {
    if (!DESCRIPTORS || call($propertyIsEnumerable, properties, key)) $defineProperty(O, key, properties[key]);
  });
  return O;
};

var $create = function create(O, Properties) {
  return Properties === undefined ? nativeObjectCreate(O) : $defineProperties(nativeObjectCreate(O), Properties);
};

var $propertyIsEnumerable = function propertyIsEnumerable(V) {
  var P = toPropertyKey(V);
  var enumerable = call(nativePropertyIsEnumerable, this, P);
  if (this === ObjectPrototype && hasOwn(AllSymbols, P) && !hasOwn(ObjectPrototypeSymbols, P)) return false;
  return enumerable || !hasOwn(this, P) || !hasOwn(AllSymbols, P) || hasOwn(this, HIDDEN) && this[HIDDEN][P]
    ? enumerable : true;
};

var $getOwnPropertyDescriptor = function getOwnPropertyDescriptor(O, P) {
  var it = toIndexedObject(O);
  var key = toPropertyKey(P);
  if (it === ObjectPrototype && hasOwn(AllSymbols, key) && !hasOwn(ObjectPrototypeSymbols, key)) return;
  var descriptor = nativeGetOwnPropertyDescriptor(it, key);
  if (descriptor && hasOwn(AllSymbols, key) && !(hasOwn(it, HIDDEN) && it[HIDDEN][key])) {
    descriptor.enumerable = true;
  }
  return descriptor;
};

var $getOwnPropertyNames = function getOwnPropertyNames(O) {
  var names = nativeGetOwnPropertyNames(toIndexedObject(O));
  var result = [];
  $forEach(names, function (key) {
    if (!hasOwn(AllSymbols, key) && !hasOwn(hiddenKeys, key)) push(result, key);
  });
  return result;
};

var $getOwnPropertySymbols = function (O) {
  var IS_OBJECT_PROTOTYPE = O === ObjectPrototype;
  var names = nativeGetOwnPropertyNames(IS_OBJECT_PROTOTYPE ? ObjectPrototypeSymbols : toIndexedObject(O));
  var result = [];
  $forEach(names, function (key) {
    if (hasOwn(AllSymbols, key) && (!IS_OBJECT_PROTOTYPE || hasOwn(ObjectPrototype, key))) {
      push(result, AllSymbols[key]);
    }
  });
  return result;
};

// `Symbol` constructor
// https://tc39.es/ecma262/#sec-symbol-constructor
if (!NATIVE_SYMBOL) {
  $Symbol = function Symbol() {
    if (isPrototypeOf(SymbolPrototype, this)) throw new TypeError('Symbol is not a constructor');
    var description = !arguments.length || arguments[0] === undefined ? undefined : $toString(arguments[0]);
    var tag = uid(description);
    var setter = function (value) {
      var $this = this === undefined ? global : this;
      if ($this === ObjectPrototype) call(setter, ObjectPrototypeSymbols, value);
      if (hasOwn($this, HIDDEN) && hasOwn($this[HIDDEN], tag)) $this[HIDDEN][tag] = false;
      var descriptor = createPropertyDescriptor(1, value);
      try {
        setSymbolDescriptor($this, tag, descriptor);
      } catch (error) {
        if (!(error instanceof RangeError)) throw error;
        fallbackDefineProperty($this, tag, descriptor);
      }
    };
    if (DESCRIPTORS && USE_SETTER) setSymbolDescriptor(ObjectPrototype, tag, { configurable: true, set: setter });
    return wrap(tag, description);
  };

  SymbolPrototype = $Symbol[PROTOTYPE];

  defineBuiltIn(SymbolPrototype, 'toString', function toString() {
    return getInternalState(this).tag;
  });

  defineBuiltIn($Symbol, 'withoutSetter', function (description) {
    return wrap(uid(description), description);
  });

  propertyIsEnumerableModule.f = $propertyIsEnumerable;
  definePropertyModule.f = $defineProperty;
  definePropertiesModule.f = $defineProperties;
  getOwnPropertyDescriptorModule.f = $getOwnPropertyDescriptor;
  getOwnPropertyNamesModule.f = getOwnPropertyNamesExternal.f = $getOwnPropertyNames;
  getOwnPropertySymbolsModule.f = $getOwnPropertySymbols;

  wrappedWellKnownSymbolModule.f = function (name) {
    return wrap(wellKnownSymbol(name), name);
  };

  if (DESCRIPTORS) {
    // https://github.com/tc39/proposal-Symbol-description
    defineBuiltInAccessor(SymbolPrototype, 'description', {
      configurable: true,
      get: function description() {
        return getInternalState(this).description;
      }
    });
    if (!IS_PURE) {
      defineBuiltIn(ObjectPrototype, 'propertyIsEnumerable', $propertyIsEnumerable, { unsafe: true });
    }
  }
}

$({ global: true, constructor: true, wrap: true, forced: !NATIVE_SYMBOL, sham: !NATIVE_SYMBOL }, {
  Symbol: $Symbol
});

$forEach(objectKeys(WellKnownSymbolsStore), function (name) {
  defineWellKnownSymbol(name);
});

$({ target: SYMBOL, stat: true, forced: !NATIVE_SYMBOL }, {
  useSetter: function () { USE_SETTER = true; },
  useSimple: function () { USE_SETTER = false; }
});

$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL, sham: !DESCRIPTORS }, {
  // `Object.create` method
  // https://tc39.es/ecma262/#sec-object.create
  create: $create,
  // `Object.defineProperty` method
  // https://tc39.es/ecma262/#sec-object.defineproperty
  defineProperty: $defineProperty,
  // `Object.defineProperties` method
  // https://tc39.es/ecma262/#sec-object.defineproperties
  defineProperties: $defineProperties,
  // `Object.getOwnPropertyDescriptor` method
  // https://tc39.es/ecma262/#sec-object.getownpropertydescriptors
  getOwnPropertyDescriptor: $getOwnPropertyDescriptor
});

$({ target: 'Object', stat: true, forced: !NATIVE_SYMBOL }, {
  // `Object.getOwnPropertyNames` method
  // https://tc39.es/ecma262/#sec-object.getownpropertynames
  getOwnPropertyNames: $getOwnPropertyNames
});

// `Symbol.prototype[@@toPrimitive]` method
// https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive
defineSymbolToPrimitive();

// `Symbol.prototype[@@toStringTag]` property
// https://tc39.es/ecma262/#sec-symbol.prototype-@@tostringtag
setToStringTag($Symbol, SYMBOL);

hiddenKeys[HIDDEN] = true;


/***/ }),

/***/ 9463:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {

// `Symbol.prototype.description` getter
// https://tc39.es/ecma262/#sec-symbol.prototype.description

var $ = __webpack_require__(6518);
var DESCRIPTORS = __webpack_require__(3724);
var global = __webpack_require__(4475);
var uncurryThis = __webpack_require__(9504);
var hasOwn = __webpack_require__(9297);
var isCallable = __webpack_require__(4901);
var isPrototypeOf = __webpack_require__(1625);
var toString = __webpack_require__(655);
var defineBuiltInAccessor = __webpack_require__(2106);
var copyConstructorProperties = __webpack_require__(7740);

var NativeSymbol = global.Symbol;
var SymbolPrototype = NativeSymbol && NativeSymbol.prototype;

if (DESCRIPTORS && isCallable(NativeSymbol) && (!('description' in SymbolPrototype) ||
  // Safari 12 bug
  NativeSymbol().description !== undefined
)) {
  var EmptyStringDescriptionStore = {};
  // wrap Symbol constructor for correct work with undefined description
  var SymbolWrapper = function Symbol() {
    var description = arguments.length < 1 || arguments[0] === undefined ? undefined : toString(arguments[0]);
    var result = isPrototypeOf(SymbolPrototype, this)
      ? new NativeSymbol(description)
      // in Edge 13, String(Symbol(undefined)) === 'Symbol(undefined)'
      : description === undefined ? NativeSymbol() : NativeSymbol(description);
    if (description === '') EmptyStringDescriptionStore[result] = true;
    return result;
  };

  copyConstructorProperties(SymbolWrapper, NativeSymbol);
  SymbolWrapper.prototype = SymbolPrototype;
  SymbolPrototype.constructor = SymbolWrapper;

  var NATIVE_SYMBOL = String(NativeSymbol('description detection')) === 'Symbol(description detection)';
  var thisSymbolValue = uncurryThis(SymbolPrototype.valueOf);
  var symbolDescriptiveString = uncurryThis(SymbolPrototype.toString);
  var regexp = /^Symbol\((.*)\)[^)]+$/;
  var replace = uncurryThis(''.replace);
  var stringSlice = uncurryThis(''.slice);

  defineBuiltInAccessor(SymbolPrototype, 'description', {
    configurable: true,
    get: function description() {
      var symbol = thisSymbolValue(this);
      if (hasOwn(EmptyStringDescriptionStore, symbol)) return '';
      var string = symbolDescriptiveString(symbol);
      var desc = NATIVE_SYMBOL ? stringSlice(string, 7, -1) : replace(string, regexp, '$1');
      return desc === '' ? undefined : desc;
    }
  });

  $({ global: true, constructor: true, forced: true }, {
    Symbol: SymbolWrapper
  });
}


/***/ }),

/***/ 1510:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var getBuiltIn = __webpack_require__(7751);
var hasOwn = __webpack_require__(9297);
var toString = __webpack_require__(655);
var shared = __webpack_require__(5745);
var NATIVE_SYMBOL_REGISTRY = __webpack_require__(1296);

var StringToSymbolRegistry = shared('string-to-symbol-registry');
var SymbolToStringRegistry = shared('symbol-to-string-registry');

// `Symbol.for` method
// https://tc39.es/ecma262/#sec-symbol.for
$({ target: 'Symbol', stat: true, forced: !NATIVE_SYMBOL_REGISTRY }, {
  'for': function (key) {
    var string = toString(key);
    if (hasOwn(StringToSymbolRegistry, string)) return StringToSymbolRegistry[string];
    var symbol = getBuiltIn('Symbol')(string);
    StringToSymbolRegistry[string] = symbol;
    SymbolToStringRegistry[symbol] = string;
    return symbol;
  }
});


/***/ }),

/***/ 2259:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var defineWellKnownSymbol = __webpack_require__(511);

// `Symbol.iterator` well-known symbol
// https://tc39.es/ecma262/#sec-symbol.iterator
defineWellKnownSymbol('iterator');


/***/ }),

/***/ 2675:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove this module from `core-js@4` since it's split to modules listed below
__webpack_require__(6761);
__webpack_require__(1510);
__webpack_require__(7812);
__webpack_require__(3110);
__webpack_require__(9773);


/***/ }),

/***/ 7812:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var $ = __webpack_require__(6518);
var hasOwn = __webpack_require__(9297);
var isSymbol = __webpack_require__(757);
var tryToString = __webpack_require__(6823);
var shared = __webpack_require__(5745);
var NATIVE_SYMBOL_REGISTRY = __webpack_require__(1296);

var SymbolToStringRegistry = shared('symbol-to-string-registry');

// `Symbol.keyFor` method
// https://tc39.es/ecma262/#sec-symbol.keyfor
$({ target: 'Symbol', stat: true, forced: !NATIVE_SYMBOL_REGISTRY }, {
  keyFor: function keyFor(sym) {
    if (!isSymbol(sym)) throw new TypeError(tryToString(sym) + ' is not a symbol');
    if (hasOwn(SymbolToStringRegistry, sym)) return SymbolToStringRegistry[sym];
  }
});


/***/ }),

/***/ 5700:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var defineWellKnownSymbol = __webpack_require__(511);
var defineSymbolToPrimitive = __webpack_require__(8242);

// `Symbol.toPrimitive` well-known symbol
// https://tc39.es/ecma262/#sec-symbol.toprimitive
defineWellKnownSymbol('toPrimitive');

// `Symbol.prototype[@@toPrimitive]` method
// https://tc39.es/ecma262/#sec-symbol.prototype-@@toprimitive
defineSymbolToPrimitive();


/***/ }),

/***/ 8125:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var getBuiltIn = __webpack_require__(7751);
var defineWellKnownSymbol = __webpack_require__(511);
var setToStringTag = __webpack_require__(687);

// `Symbol.toStringTag` well-known symbol
// https://tc39.es/ecma262/#sec-symbol.tostringtag
defineWellKnownSymbol('toStringTag');

// `Symbol.prototype[@@toStringTag]` property
// https://tc39.es/ecma262/#sec-symbol.prototype-@@tostringtag
setToStringTag(getBuiltIn('Symbol'), 'Symbol');


/***/ }),

/***/ 8140:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var lengthOfArrayLike = __webpack_require__(6198);
var toIntegerOrInfinity = __webpack_require__(1291);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.at` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.at
exportTypedArrayMethod('at', function at(index) {
  var O = aTypedArray(this);
  var len = lengthOfArrayLike(O);
  var relativeIndex = toIntegerOrInfinity(index);
  var k = relativeIndex >= 0 ? relativeIndex : len + relativeIndex;
  return (k < 0 || k >= len) ? undefined : O[k];
});


/***/ }),

/***/ 1630:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var uncurryThis = __webpack_require__(9504);
var ArrayBufferViewCore = __webpack_require__(4644);
var $ArrayCopyWithin = __webpack_require__(7029);

var u$ArrayCopyWithin = uncurryThis($ArrayCopyWithin);
var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.copyWithin` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.copywithin
exportTypedArrayMethod('copyWithin', function copyWithin(target, start /* , end */) {
  return u$ArrayCopyWithin(aTypedArray(this), target, start, arguments.length > 2 ? arguments[2] : undefined);
});


/***/ }),

/***/ 2170:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $every = (__webpack_require__(9213).every);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.every` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.every
exportTypedArrayMethod('every', function every(callbackfn /* , thisArg */) {
  return $every(aTypedArray(this), callbackfn, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 5044:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $fill = __webpack_require__(4373);
var toBigInt = __webpack_require__(5854);
var classof = __webpack_require__(6955);
var call = __webpack_require__(9565);
var uncurryThis = __webpack_require__(9504);
var fails = __webpack_require__(9039);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var slice = uncurryThis(''.slice);

// V8 ~ Chrome < 59, Safari < 14.1, FF < 55, Edge <=18
var CONVERSION_BUG = fails(function () {
  var count = 0;
  // eslint-disable-next-line es/no-typed-arrays -- safe
  new Int8Array(2).fill({ valueOf: function () { return count++; } });
  return count !== 1;
});

// `%TypedArray%.prototype.fill` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.fill
exportTypedArrayMethod('fill', function fill(value /* , start, end */) {
  var length = arguments.length;
  aTypedArray(this);
  var actualValue = slice(classof(this), 0, 3) === 'Big' ? toBigInt(value) : +value;
  return call($fill, this, actualValue, length > 1 ? arguments[1] : undefined, length > 2 ? arguments[2] : undefined);
}, CONVERSION_BUG);


/***/ }),

/***/ 1920:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $filter = (__webpack_require__(9213).filter);
var fromSpeciesAndList = __webpack_require__(6357);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.filter` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.filter
exportTypedArrayMethod('filter', function filter(callbackfn /* , thisArg */) {
  var list = $filter(aTypedArray(this), callbackfn, arguments.length > 1 ? arguments[1] : undefined);
  return fromSpeciesAndList(this, list);
});


/***/ }),

/***/ 9955:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $findIndex = (__webpack_require__(9213).findIndex);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.findIndex` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.findindex
exportTypedArrayMethod('findIndex', function findIndex(predicate /* , thisArg */) {
  return $findIndex(aTypedArray(this), predicate, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 1134:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $findLastIndex = (__webpack_require__(3839).findLastIndex);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.findLastIndex` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.findlastindex
exportTypedArrayMethod('findLastIndex', function findLastIndex(predicate /* , thisArg */) {
  return $findLastIndex(aTypedArray(this), predicate, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 1903:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $findLast = (__webpack_require__(3839).findLast);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.findLast` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.findlast
exportTypedArrayMethod('findLast', function findLast(predicate /* , thisArg */) {
  return $findLast(aTypedArray(this), predicate, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 1694:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $find = (__webpack_require__(9213).find);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.find` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.find
exportTypedArrayMethod('find', function find(predicate /* , thisArg */) {
  return $find(aTypedArray(this), predicate, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 4594:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var createTypedArrayConstructor = __webpack_require__(5823);

// `Float32Array` constructor
// https://tc39.es/ecma262/#sec-typedarray-objects
createTypedArrayConstructor('Float32', function (init) {
  return function Float32Array(data, byteOffset, length) {
    return init(this, data, byteOffset, length);
  };
});


/***/ }),

/***/ 3206:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $forEach = (__webpack_require__(9213).forEach);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.forEach` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.foreach
exportTypedArrayMethod('forEach', function forEach(callbackfn /* , thisArg */) {
  $forEach(aTypedArray(this), callbackfn, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 8345:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var TYPED_ARRAYS_CONSTRUCTORS_REQUIRES_WRAPPERS = __webpack_require__(2805);
var exportTypedArrayStaticMethod = (__webpack_require__(4644).exportTypedArrayStaticMethod);
var typedArrayFrom = __webpack_require__(3251);

// `%TypedArray%.from` method
// https://tc39.es/ecma262/#sec-%typedarray%.from
exportTypedArrayStaticMethod('from', typedArrayFrom, TYPED_ARRAYS_CONSTRUCTORS_REQUIRES_WRAPPERS);


/***/ }),

/***/ 4496:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $includes = (__webpack_require__(9617).includes);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.includes` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.includes
exportTypedArrayMethod('includes', function includes(searchElement /* , fromIndex */) {
  return $includes(aTypedArray(this), searchElement, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 6651:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $indexOf = (__webpack_require__(9617).indexOf);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.indexOf` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.indexof
exportTypedArrayMethod('indexOf', function indexOf(searchElement /* , fromIndex */) {
  return $indexOf(aTypedArray(this), searchElement, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 2887:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var fails = __webpack_require__(9039);
var uncurryThis = __webpack_require__(9504);
var ArrayBufferViewCore = __webpack_require__(4644);
var ArrayIterators = __webpack_require__(3792);
var wellKnownSymbol = __webpack_require__(8227);

var ITERATOR = wellKnownSymbol('iterator');
var Uint8Array = global.Uint8Array;
var arrayValues = uncurryThis(ArrayIterators.values);
var arrayKeys = uncurryThis(ArrayIterators.keys);
var arrayEntries = uncurryThis(ArrayIterators.entries);
var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var TypedArrayPrototype = Uint8Array && Uint8Array.prototype;

var GENERIC = !fails(function () {
  TypedArrayPrototype[ITERATOR].call([1]);
});

var ITERATOR_IS_VALUES = !!TypedArrayPrototype
  && TypedArrayPrototype.values
  && TypedArrayPrototype[ITERATOR] === TypedArrayPrototype.values
  && TypedArrayPrototype.values.name === 'values';

var typedArrayValues = function values() {
  return arrayValues(aTypedArray(this));
};

// `%TypedArray%.prototype.entries` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.entries
exportTypedArrayMethod('entries', function entries() {
  return arrayEntries(aTypedArray(this));
}, GENERIC);
// `%TypedArray%.prototype.keys` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.keys
exportTypedArrayMethod('keys', function keys() {
  return arrayKeys(aTypedArray(this));
}, GENERIC);
// `%TypedArray%.prototype.values` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.values
exportTypedArrayMethod('values', typedArrayValues, GENERIC || !ITERATOR_IS_VALUES, { name: 'values' });
// `%TypedArray%.prototype[@@iterator]` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype-@@iterator
exportTypedArrayMethod(ITERATOR, typedArrayValues, GENERIC || !ITERATOR_IS_VALUES, { name: 'values' });


/***/ }),

/***/ 9369:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var uncurryThis = __webpack_require__(9504);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var $join = uncurryThis([].join);

// `%TypedArray%.prototype.join` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.join
exportTypedArrayMethod('join', function join(separator) {
  return $join(aTypedArray(this), separator);
});


/***/ }),

/***/ 6812:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var apply = __webpack_require__(8745);
var $lastIndexOf = __webpack_require__(8379);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.lastIndexOf` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.lastindexof
exportTypedArrayMethod('lastIndexOf', function lastIndexOf(searchElement /* , fromIndex */) {
  var length = arguments.length;
  return apply($lastIndexOf, aTypedArray(this), length > 1 ? [searchElement, arguments[1]] : [searchElement]);
});


/***/ }),

/***/ 8995:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $map = (__webpack_require__(9213).map);
var typedArraySpeciesConstructor = __webpack_require__(1412);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.map` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.map
exportTypedArrayMethod('map', function map(mapfn /* , thisArg */) {
  return $map(aTypedArray(this), mapfn, arguments.length > 1 ? arguments[1] : undefined, function (O, length) {
    return new (typedArraySpeciesConstructor(O))(length);
  });
});


/***/ }),

/***/ 6072:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $reduceRight = (__webpack_require__(926).right);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.reduceRight` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.reduceright
exportTypedArrayMethod('reduceRight', function reduceRight(callbackfn /* , initialValue */) {
  var length = arguments.length;
  return $reduceRight(aTypedArray(this), callbackfn, length, length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 1575:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $reduce = (__webpack_require__(926).left);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.reduce` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.reduce
exportTypedArrayMethod('reduce', function reduce(callbackfn /* , initialValue */) {
  var length = arguments.length;
  return $reduce(aTypedArray(this), callbackfn, length, length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 8747:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var floor = Math.floor;

// `%TypedArray%.prototype.reverse` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.reverse
exportTypedArrayMethod('reverse', function reverse() {
  var that = this;
  var length = aTypedArray(that).length;
  var middle = floor(length / 2);
  var index = 0;
  var value;
  while (index < middle) {
    value = that[index];
    that[index++] = that[--length];
    that[length] = value;
  } return that;
});


/***/ }),

/***/ 8845:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var call = __webpack_require__(9565);
var ArrayBufferViewCore = __webpack_require__(4644);
var lengthOfArrayLike = __webpack_require__(6198);
var toOffset = __webpack_require__(8229);
var toIndexedObject = __webpack_require__(8981);
var fails = __webpack_require__(9039);

var RangeError = global.RangeError;
var Int8Array = global.Int8Array;
var Int8ArrayPrototype = Int8Array && Int8Array.prototype;
var $set = Int8ArrayPrototype && Int8ArrayPrototype.set;
var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

var WORKS_WITH_OBJECTS_AND_GENERIC_ON_TYPED_ARRAYS = !fails(function () {
  // eslint-disable-next-line es/no-typed-arrays -- required for testing
  var array = new Uint8ClampedArray(2);
  call($set, array, { length: 1, 0: 3 }, 1);
  return array[1] !== 3;
});

// https://bugs.chromium.org/p/v8/issues/detail?id=11294 and other
var TO_OBJECT_BUG = WORKS_WITH_OBJECTS_AND_GENERIC_ON_TYPED_ARRAYS && ArrayBufferViewCore.NATIVE_ARRAY_BUFFER_VIEWS && fails(function () {
  var array = new Int8Array(2);
  array.set(1);
  array.set('2', 1);
  return array[0] !== 0 || array[1] !== 2;
});

// `%TypedArray%.prototype.set` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.set
exportTypedArrayMethod('set', function set(arrayLike /* , offset */) {
  aTypedArray(this);
  var offset = toOffset(arguments.length > 1 ? arguments[1] : undefined, 1);
  var src = toIndexedObject(arrayLike);
  if (WORKS_WITH_OBJECTS_AND_GENERIC_ON_TYPED_ARRAYS) return call($set, this, src, offset);
  var length = this.length;
  var len = lengthOfArrayLike(src);
  var index = 0;
  if (len + offset > length) throw new RangeError('Wrong length');
  while (index < len) this[offset + index] = src[index++];
}, !WORKS_WITH_OBJECTS_AND_GENERIC_ON_TYPED_ARRAYS || TO_OBJECT_BUG);


/***/ }),

/***/ 9423:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var typedArraySpeciesConstructor = __webpack_require__(1412);
var fails = __webpack_require__(9039);
var arraySlice = __webpack_require__(7680);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

var FORCED = fails(function () {
  // eslint-disable-next-line es/no-typed-arrays -- required for testing
  new Int8Array(1).slice();
});

// `%TypedArray%.prototype.slice` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.slice
exportTypedArrayMethod('slice', function slice(start, end) {
  var list = arraySlice(aTypedArray(this), start, end);
  var C = typedArraySpeciesConstructor(this);
  var index = 0;
  var length = list.length;
  var result = new C(length);
  while (length > index) result[index] = list[index++];
  return result;
}, FORCED);


/***/ }),

/***/ 7301:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var $some = (__webpack_require__(9213).some);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

// `%TypedArray%.prototype.some` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.some
exportTypedArrayMethod('some', function some(callbackfn /* , thisArg */) {
  return $some(aTypedArray(this), callbackfn, arguments.length > 1 ? arguments[1] : undefined);
});


/***/ }),

/***/ 373:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var uncurryThis = __webpack_require__(7476);
var fails = __webpack_require__(9039);
var aCallable = __webpack_require__(9306);
var internalSort = __webpack_require__(4488);
var ArrayBufferViewCore = __webpack_require__(4644);
var FF = __webpack_require__(8834);
var IE_OR_EDGE = __webpack_require__(3202);
var V8 = __webpack_require__(7388);
var WEBKIT = __webpack_require__(9160);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var Uint16Array = global.Uint16Array;
var nativeSort = Uint16Array && uncurryThis(Uint16Array.prototype.sort);

// WebKit
var ACCEPT_INCORRECT_ARGUMENTS = !!nativeSort && !(fails(function () {
  nativeSort(new Uint16Array(2), null);
}) && fails(function () {
  nativeSort(new Uint16Array(2), {});
}));

var STABLE_SORT = !!nativeSort && !fails(function () {
  // feature detection can be too slow, so check engines versions
  if (V8) return V8 < 74;
  if (FF) return FF < 67;
  if (IE_OR_EDGE) return true;
  if (WEBKIT) return WEBKIT < 602;

  var array = new Uint16Array(516);
  var expected = Array(516);
  var index, mod;

  for (index = 0; index < 516; index++) {
    mod = index % 4;
    array[index] = 515 - index;
    expected[index] = index - 2 * mod + 3;
  }

  nativeSort(array, function (a, b) {
    return (a / 4 | 0) - (b / 4 | 0);
  });

  for (index = 0; index < 516; index++) {
    if (array[index] !== expected[index]) return true;
  }
});

var getSortCompare = function (comparefn) {
  return function (x, y) {
    if (comparefn !== undefined) return +comparefn(x, y) || 0;
    // eslint-disable-next-line no-self-compare -- NaN check
    if (y !== y) return -1;
    // eslint-disable-next-line no-self-compare -- NaN check
    if (x !== x) return 1;
    if (x === 0 && y === 0) return 1 / x > 0 && 1 / y < 0 ? 1 : -1;
    return x > y;
  };
};

// `%TypedArray%.prototype.sort` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.sort
exportTypedArrayMethod('sort', function sort(comparefn) {
  if (comparefn !== undefined) aCallable(comparefn);
  if (STABLE_SORT) return nativeSort(this, comparefn);

  return internalSort(aTypedArray(this), getSortCompare(comparefn));
}, !STABLE_SORT || ACCEPT_INCORRECT_ARGUMENTS);


/***/ }),

/***/ 1405:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var apply = __webpack_require__(8745);
var ArrayBufferViewCore = __webpack_require__(4644);
var fails = __webpack_require__(9039);
var arraySlice = __webpack_require__(7680);

var Int8Array = global.Int8Array;
var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var $toLocaleString = [].toLocaleString;

// iOS Safari 6.x fails here
var TO_LOCALE_STRING_BUG = !!Int8Array && fails(function () {
  $toLocaleString.call(new Int8Array(1));
});

var FORCED = fails(function () {
  return [1, 2].toLocaleString() !== new Int8Array([1, 2]).toLocaleString();
}) || !fails(function () {
  Int8Array.prototype.toLocaleString.call([1, 2]);
});

// `%TypedArray%.prototype.toLocaleString` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.tolocalestring
exportTypedArrayMethod('toLocaleString', function toLocaleString() {
  return apply(
    $toLocaleString,
    TO_LOCALE_STRING_BUG ? arraySlice(aTypedArray(this)) : aTypedArray(this),
    arraySlice(arguments)
  );
}, FORCED);


/***/ }),

/***/ 7467:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var arrayToReversed = __webpack_require__(7628);
var ArrayBufferViewCore = __webpack_require__(4644);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;

// `%TypedArray%.prototype.toReversed` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.toreversed
exportTypedArrayMethod('toReversed', function toReversed() {
  return arrayToReversed(aTypedArray(this), getTypedArrayConstructor(this));
});


/***/ }),

/***/ 4732:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var ArrayBufferViewCore = __webpack_require__(4644);
var uncurryThis = __webpack_require__(9504);
var aCallable = __webpack_require__(9306);
var arrayFromConstructorAndList = __webpack_require__(5370);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
var sort = uncurryThis(ArrayBufferViewCore.TypedArrayPrototype.sort);

// `%TypedArray%.prototype.toSorted` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.tosorted
exportTypedArrayMethod('toSorted', function toSorted(compareFn) {
  if (compareFn !== undefined) aCallable(compareFn);
  var O = aTypedArray(this);
  var A = arrayFromConstructorAndList(getTypedArrayConstructor(O), O);
  return sort(A, compareFn);
});


/***/ }),

/***/ 3684:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var exportTypedArrayMethod = (__webpack_require__(4644).exportTypedArrayMethod);
var fails = __webpack_require__(9039);
var global = __webpack_require__(4475);
var uncurryThis = __webpack_require__(9504);

var Uint8Array = global.Uint8Array;
var Uint8ArrayPrototype = Uint8Array && Uint8Array.prototype || {};
var arrayToString = [].toString;
var join = uncurryThis([].join);

if (fails(function () { arrayToString.call({}); })) {
  arrayToString = function toString() {
    return join(this);
  };
}

var IS_NOT_ARRAY_METHOD = Uint8ArrayPrototype.toString !== arrayToString;

// `%TypedArray%.prototype.toString` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.tostring
exportTypedArrayMethod('toString', arrayToString, IS_NOT_ARRAY_METHOD);


/***/ }),

/***/ 3690:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var createTypedArrayConstructor = __webpack_require__(5823);

// `Uint16Array` constructor
// https://tc39.es/ecma262/#sec-typedarray-objects
createTypedArrayConstructor('Uint16', function (init) {
  return function Uint16Array(data, byteOffset, length) {
    return init(this, data, byteOffset, length);
  };
});


/***/ }),

/***/ 1489:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var createTypedArrayConstructor = __webpack_require__(5823);

// `Uint8Array` constructor
// https://tc39.es/ecma262/#sec-typedarray-objects
createTypedArrayConstructor('Uint8', function (init) {
  return function Uint8Array(data, byteOffset, length) {
    return init(this, data, byteOffset, length);
  };
});


/***/ }),

/***/ 9577:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var arrayWith = __webpack_require__(9928);
var ArrayBufferViewCore = __webpack_require__(4644);
var isBigIntArray = __webpack_require__(1108);
var toIntegerOrInfinity = __webpack_require__(1291);
var toBigInt = __webpack_require__(5854);

var aTypedArray = ArrayBufferViewCore.aTypedArray;
var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;

var PROPER_ORDER = !!function () {
  try {
    // eslint-disable-next-line no-throw-literal, es/no-typed-arrays, es/no-array-prototype-with -- required for testing
    new Int8Array(1)['with'](2, { valueOf: function () { throw 8; } });
  } catch (error) {
    // some early implementations, like WebKit, does not follow the final semantic
    // https://github.com/tc39/proposal-change-array-by-copy/pull/86
    return error === 8;
  }
}();

// `%TypedArray%.prototype.with` method
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.with
exportTypedArrayMethod('with', { 'with': function (index, value) {
  var O = aTypedArray(this);
  var relativeIndex = toIntegerOrInfinity(index);
  var actualValue = isBigIntArray(O) ? toBigInt(value) : +value;
  return arrayWith(O, getTypedArrayConstructor(O), relativeIndex, actualValue);
} }['with'], !PROPER_ORDER);


/***/ }),

/***/ 3899:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove from `core-js@4`
__webpack_require__(6573);


/***/ }),

/***/ 7801:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove from `core-js@4`
__webpack_require__(7936);


/***/ }),

/***/ 7913:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove from `core-js@4`
__webpack_require__(8100);


/***/ }),

/***/ 3500:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var DOMIterables = __webpack_require__(7400);
var DOMTokenListPrototype = __webpack_require__(9296);
var forEach = __webpack_require__(235);
var createNonEnumerableProperty = __webpack_require__(6699);

var handlePrototype = function (CollectionPrototype) {
  // some Chrome versions have non-configurable methods on DOMTokenList
  if (CollectionPrototype && CollectionPrototype.forEach !== forEach) try {
    createNonEnumerableProperty(CollectionPrototype, 'forEach', forEach);
  } catch (error) {
    CollectionPrototype.forEach = forEach;
  }
};

for (var COLLECTION_NAME in DOMIterables) {
  if (DOMIterables[COLLECTION_NAME]) {
    handlePrototype(global[COLLECTION_NAME] && global[COLLECTION_NAME].prototype);
  }
}

handlePrototype(DOMTokenListPrototype);


/***/ }),

/***/ 2953:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var global = __webpack_require__(4475);
var DOMIterables = __webpack_require__(7400);
var DOMTokenListPrototype = __webpack_require__(9296);
var ArrayIteratorMethods = __webpack_require__(3792);
var createNonEnumerableProperty = __webpack_require__(6699);
var setToStringTag = __webpack_require__(687);
var wellKnownSymbol = __webpack_require__(8227);

var ITERATOR = wellKnownSymbol('iterator');
var ArrayValues = ArrayIteratorMethods.values;

var handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {
  if (CollectionPrototype) {
    // some Chrome versions have non-configurable methods on DOMTokenList
    if (CollectionPrototype[ITERATOR] !== ArrayValues) try {
      createNonEnumerableProperty(CollectionPrototype, ITERATOR, ArrayValues);
    } catch (error) {
      CollectionPrototype[ITERATOR] = ArrayValues;
    }
    setToStringTag(CollectionPrototype, COLLECTION_NAME, true);
    if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {
      // some Chrome versions have non-configurable methods on DOMTokenList
      if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {
        createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);
      } catch (error) {
        CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];
      }
    }
  }
};

for (var COLLECTION_NAME in DOMIterables) {
  handlePrototype(global[COLLECTION_NAME] && global[COLLECTION_NAME].prototype, COLLECTION_NAME);
}

handlePrototype(DOMTokenListPrototype, 'DOMTokenList');


/***/ }),

/***/ 8406:
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {


// TODO: in core-js@4, move /modules/ dependencies to public entries for better optimization by tools like `preset-env`
__webpack_require__(3792);
var $ = __webpack_require__(6518);
var global = __webpack_require__(4475);
var safeGetBuiltIn = __webpack_require__(3389);
var call = __webpack_require__(9565);
var uncurryThis = __webpack_require__(9504);
var DESCRIPTORS = __webpack_require__(3724);
var USE_NATIVE_URL = __webpack_require__(7416);
var defineBuiltIn = __webpack_require__(6840);
var defineBuiltInAccessor = __webpack_require__(2106);
var defineBuiltIns = __webpack_require__(6279);
var setToStringTag = __webpack_require__(687);
var createIteratorConstructor = __webpack_require__(3994);
var InternalStateModule = __webpack_require__(1181);
var anInstance = __webpack_require__(679);
var isCallable = __webpack_require__(4901);
var hasOwn = __webpack_require__(9297);
var bind = __webpack_require__(6080);
var classof = __webpack_require__(6955);
var anObject = __webpack_require__(8551);
var isObject = __webpack_require__(34);
var $toString = __webpack_require__(655);
var create = __webpack_require__(2360);
var createPropertyDescriptor = __webpack_require__(6980);
var getIterator = __webpack_require__(81);
var getIteratorMethod = __webpack_require__(851);
var createIterResultObject = __webpack_require__(2529);
var validateArgumentsLength = __webpack_require__(2812);
var wellKnownSymbol = __webpack_require__(8227);
var arraySort = __webpack_require__(4488);

var ITERATOR = wellKnownSymbol('iterator');
var URL_SEARCH_PARAMS = 'URLSearchParams';
var URL_SEARCH_PARAMS_ITERATOR = URL_SEARCH_PARAMS + 'Iterator';
var setInternalState = InternalStateModule.set;
var getInternalParamsState = InternalStateModule.getterFor(URL_SEARCH_PARAMS);
var getInternalIteratorState = InternalStateModule.getterFor(URL_SEARCH_PARAMS_ITERATOR);

var nativeFetch = safeGetBuiltIn('fetch');
var NativeRequest = safeGetBuiltIn('Request');
var Headers = safeGetBuiltIn('Headers');
var RequestPrototype = NativeRequest && NativeRequest.prototype;
var HeadersPrototype = Headers && Headers.prototype;
var RegExp = global.RegExp;
var TypeError = global.TypeError;
var decodeURIComponent = global.decodeURIComponent;
var encodeURIComponent = global.encodeURIComponent;
var charAt = uncurryThis(''.charAt);
var join = uncurryThis([].join);
var push = uncurryThis([].push);
var replace = uncurryThis(''.replace);
var shift = uncurryThis([].shift);
var splice = uncurryThis([].splice);
var split = uncurryThis(''.split);
var stringSlice = uncurryThis(''.slice);

var plus = /\+/g;
var sequences = Array(4);

var percentSequence = function (bytes) {
  return sequences[bytes - 1] || (sequences[bytes - 1] = RegExp('((?:%[\\da-f]{2}){' + bytes + '})', 'gi'));
};

var percentDecode = function (sequence) {
  try {
    return decodeURIComponent(sequence);
  } catch (error) {
    return sequence;
  }
};

var deserialize = function (it) {
  var result = replace(it, plus, ' ');
  var bytes = 4;
  try {
    return decodeURIComponent(result);
  } catch (error) {
    while (bytes) {
      result = replace(result, percentSequence(bytes--), percentDecode);
    }
    return result;
  }
};

var find = /[!'()~]|%20/g;

var replacements = {
  '!': '%21',
  "'": '%27',
  '(': '%28',
  ')': '%29',
  '~': '%7E',
  '%20': '+'
};

var replacer = function (match) {
  return replacements[match];
};

var serialize = function (it) {
  return replace(encodeURIComponent(it), find, replacer);
};

var URLSearchParamsIterator = createIteratorConstructor(function Iterator(params, kind) {
  setInternalState(this, {
    type: URL_SEARCH_PARAMS_ITERATOR,
    target: getInternalParamsState(params).entries,
    index: 0,
    kind: kind
  });
}, URL_SEARCH_PARAMS, function next() {
  var state = getInternalIteratorState(this);
  var target = state.target;
  var index = state.index++;
  if (!target || index >= target.length) {
    state.target = undefined;
    return createIterResultObject(undefined, true);
  }
  var entry = target[index];
  switch (state.kind) {
    case 'keys': return createIterResultObject(entry.key, false);
    case 'values': return createIterResultObject(entry.value, false);
  } return createIterResultObject([entry.key, entry.value], false);
}, true);

var URLSearchParamsState = function (init) {
  this.entries = [];
  this.url = null;

  if (init !== undefined) {
    if (isObject(init)) this.parseObject(init);
    else this.parseQuery(typeof init == 'string' ? charAt(init, 0) === '?' ? stringSlice(init, 1) : init : $toString(init));
  }
};

URLSearchParamsState.prototype = {
  type: URL_SEARCH_PARAMS,
  bindURL: function (url) {
    this.url = url;
    this.update();
  },
  parseObject: function (object) {
    var entries = this.entries;
    var iteratorMethod = getIteratorMethod(object);
    var iterator, next, step, entryIterator, entryNext, first, second;

    if (iteratorMethod) {
      iterator = getIterator(object, iteratorMethod);
      next = iterator.next;
      while (!(step = call(next, iterator)).done) {
        entryIterator = getIterator(anObject(step.value));
        entryNext = entryIterator.next;
        if (
          (first = call(entryNext, entryIterator)).done ||
          (second = call(entryNext, entryIterator)).done ||
          !call(entryNext, entryIterator).done
        ) throw new TypeError('Expected sequence with length 2');
        push(entries, { key: $toString(first.value), value: $toString(second.value) });
      }
    } else for (var key in object) if (hasOwn(object, key)) {
      push(entries, { key: key, value: $toString(object[key]) });
    }
  },
  parseQuery: function (query) {
    if (query) {
      var entries = this.entries;
      var attributes = split(query, '&');
      var index = 0;
      var attribute, entry;
      while (index < attributes.length) {
        attribute = attributes[index++];
        if (attribute.length) {
          entry = split(attribute, '=');
          push(entries, {
            key: deserialize(shift(entry)),
            value: deserialize(join(entry, '='))
          });
        }
      }
    }
  },
  serialize: function () {
    var entries = this.entries;
    var result = [];
    var index = 0;
    var entry;
    while (index < entries.length) {
      entry = entries[index++];
      push(result, serialize(entry.key) + '=' + serialize(entry.value));
    } return join(result, '&');
  },
  update: function () {
    this.entries.length = 0;
    this.parseQuery(this.url.query);
  },
  updateURL: function () {
    if (this.url) this.url.update();
  }
};

// `URLSearchParams` constructor
// https://url.spec.whatwg.org/#interface-urlsearchparams
var URLSearchParamsConstructor = function URLSearchParams(/* init */) {
  anInstance(this, URLSearchParamsPrototype);
  var init = arguments.length > 0 ? arguments[0] : undefined;
  var state = setInternalState(this, new URLSearchParamsState(init));
  if (!DESCRIPTORS) this.size = state.entries.length;
};

var URLSearchParamsPrototype = URLSearchParamsConstructor.prototype;

defineBuiltIns(URLSearchParamsPrototype, {
  // `URLSearchParams.prototype.append` method
  // https://url.spec.whatwg.org/#dom-urlsearchparams-append
  append: function append(name, value) {
    var state = getInternalParamsState(this);
    validateArgumentsLength(arguments.length, 2);
    push(state.entries, { key: $toString(name), value: $toString(value) });
    if (!DESCRIPTORS) this.length++;
    state.updateURL();
  },
  // `URLSearchParams.prototype.delete` method
  // https://url.spec.whatwg.org/#dom-urlsearchparams-delete
  'delete': function (name /* , value */) {
    var state = getInternalParamsState(this);
    var length = validateArgumentsLength(arguments.length, 1);
    var entries = state.entries;
    var key = $toString(name);
    var $value = length < 2 ? undefined : arguments[1];
    var value = $value === undefined ? $value : $toString($value);
    var index = 0;
    while (index < entries.length) {
      var entry = entries[index];
      if (entry.key === key && (value === undefined || entry.value === value)) {
        splice(entries, index, 1);
        if (value !== undefined) break;
      } else index++;
    }
    if (!DESCRIPTORS) this.size = entries.length;
    state.updateURL();
  },
  // `URLSearchParams.prototype.get` method
  // https://url.spec.whatwg.org/#dom-urlsearchparams-get
  get: function get(name) {
    var entries = getInternalParamsState(this).entries;
    validateArgumentsLength(arguments.length, 1);
    var key = $toString(name);
    var index = 0;
    for (; index < entries.length; index++) {
      if (entries[index].key === key) return entries[index].value;
    }
    return null;
  },
  // `URLSearchParams.prototype.getAll` method
  // https://url.spec.whatwg.org/#dom-urlsearchparams-getall
  getAll: function getAll(name) {
    var entries = getInternalParamsState(this).entries;
    validateArgumentsLength(arguments.length, 1);
    var key = $toString(name);
    var result = [];
    var index = 0;
    for (; index < entries.length; index++) {
      if (entries[index].key === key) push(result, entries[index].value);
    }
    return result;
  },
  // `URLSearchParams.prototype.has` method
  // https://url.spec.whatwg.org/#dom-urlsearchparams-has
  has: function has(name /* , value */) {
    var entries = getInternalParamsState(this).entries;
    var length = validateArgumentsLength(arguments.length, 1);
    var key = $toString(name);
    var $value = length < 2 ? undefined : arguments[1];
    var value = $value === undefined ? $value : $toString($value);
    var index = 0;
    while (index < entries.length) {
      var entry = entries[index++];
      if (entry.key === key && (value === undefined || entry.value === value)) return true;
    }
    return false;
  },
  // `URLSearchParams.prototype.set` method
  // https://url.spec.whatwg.org/#dom-urlsearchparams-set
  set: function set(name, value) {
    var state = getInternalParamsState(this);
    validateArgumentsLength(arguments.length, 1);
    var entries = state.entries;
    var found = false;
    var key = $toString(name);
    var val = $toString(value);
    var index = 0;
    var entry;
    for (; index < entries.length; index++) {
      entry = entries[index];
      if (entry.key === key) {
        if (found) splice(entries, index--, 1);
        else {
          found = true;
          entry.value = val;
        }
      }
    }
    if (!found) push(entries, { key: key, value: val });
    if (!DESCRIPTORS) this.size = entries.length;
    state.updateURL();
  },
  // `URLSearchParams.prototype.sort` method
  // https://url.spec.whatwg.org/#dom-urlsearchparams-sort
  sort: function sort() {
    var state = getInternalParamsState(this);
    arraySort(state.entries, function (a, b) {
      return a.key > b.key ? 1 : -1;
    });
    state.updateURL();
  },
  // `URLSearchParams.prototype.forEach` method
  forEach: function forEach(callback /* , thisArg */) {
    var entries = getInternalParamsState(this).entries;
    var boundFunction = bind(callback, arguments.length > 1 ? arguments[1] : undefined);
    var index = 0;
    var entry;
    while (index < entries.length) {
      entry = entries[index++];
      boundFunction(entry.value, entry.key, this);
    }
  },
  // `URLSearchParams.prototype.keys` method
  keys: function keys() {
    return new URLSearchParamsIterator(this, 'keys');
  },
  // `URLSearchParams.prototype.values` method
  values: function values() {
    return new URLSearchParamsIterator(this, 'values');
  },
  // `URLSearchParams.prototype.entries` method
  entries: function entries() {
    return new URLSearchParamsIterator(this, 'entries');
  }
}, { enumerable: true });

// `URLSearchParams.prototype[@@iterator]` method
defineBuiltIn(URLSearchParamsPrototype, ITERATOR, URLSearchParamsPrototype.entries, { name: 'entries' });

// `URLSearchParams.prototype.toString` method
// https://url.spec.whatwg.org/#urlsearchparams-stringification-behavior
defineBuiltIn(URLSearchParamsPrototype, 'toString', function toString() {
  return getInternalParamsState(this).serialize();
}, { enumerable: true });

// `URLSearchParams.prototype.size` getter
// https://github.com/whatwg/url/pull/734
if (DESCRIPTORS) defineBuiltInAccessor(URLSearchParamsPrototype, 'size', {
  get: function size() {
    return getInternalParamsState(this).entries.length;
  },
  configurable: true,
  enumerable: true
});

setToStringTag(URLSearchParamsConstructor, URL_SEARCH_PARAMS);

$({ global: true, constructor: true, forced: !USE_NATIVE_URL }, {
  URLSearchParams: URLSearchParamsConstructor
});

// Wrap `fetch` and `Request` for correct work with polyfilled `URLSearchParams`
if (!USE_NATIVE_URL && isCallable(Headers)) {
  var headersHas = uncurryThis(HeadersPrototype.has);
  var headersSet = uncurryThis(HeadersPrototype.set);

  var wrapRequestOptions = function (init) {
    if (isObject(init)) {
      var body = init.body;
      var headers;
      if (classof(body) === URL_SEARCH_PARAMS) {
        headers = init.headers ? new Headers(init.headers) : new Headers();
        if (!headersHas(headers, 'content-type')) {
          headersSet(headers, 'content-type', 'application/x-www-form-urlencoded;charset=UTF-8');
        }
        return create(init, {
          body: createPropertyDescriptor(0, $toString(body)),
          headers: createPropertyDescriptor(0, headers)
        });
      }
    } return init;
  };

  if (isCallable(nativeFetch)) {
    $({ global: true, enumerable: true, dontCallGetSet: true, forced: true }, {
      fetch: function fetch(input /* , init */) {
        return nativeFetch(input, arguments.length > 1 ? wrapRequestOptions(arguments[1]) : {});
      }
    });
  }

  if (isCallable(NativeRequest)) {
    var RequestConstructor = function Request(input /* , init */) {
      anInstance(this, RequestPrototype);
      return new NativeRequest(input, arguments.length > 1 ? wrapRequestOptions(arguments[1]) : {});
    };

    RequestPrototype.constructor = RequestConstructor;
    RequestConstructor.prototype = RequestPrototype;

    $({ global: true, constructor: true, dontCallGetSet: true, forced: true }, {
      Request: RequestConstructor
    });
  }
}

module.exports = {
  URLSearchParams: URLSearchParamsConstructor,
  getState: getInternalParamsState
};


/***/ }),

/***/ 4603:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var defineBuiltIn = __webpack_require__(6840);
var uncurryThis = __webpack_require__(9504);
var toString = __webpack_require__(655);
var validateArgumentsLength = __webpack_require__(2812);

var $URLSearchParams = URLSearchParams;
var URLSearchParamsPrototype = $URLSearchParams.prototype;
var append = uncurryThis(URLSearchParamsPrototype.append);
var $delete = uncurryThis(URLSearchParamsPrototype['delete']);
var forEach = uncurryThis(URLSearchParamsPrototype.forEach);
var push = uncurryThis([].push);
var params = new $URLSearchParams('a=1&a=2&b=3');

params['delete']('a', 1);
// `undefined` case is a Chromium 117 bug
// https://bugs.chromium.org/p/v8/issues/detail?id=14222
params['delete']('b', undefined);

if (params + '' !== 'a=2') {
  defineBuiltIn(URLSearchParamsPrototype, 'delete', function (name /* , value */) {
    var length = arguments.length;
    var $value = length < 2 ? undefined : arguments[1];
    if (length && $value === undefined) return $delete(this, name);
    var entries = [];
    forEach(this, function (v, k) { // also validates `this`
      push(entries, { key: k, value: v });
    });
    validateArgumentsLength(length, 1);
    var key = toString(name);
    var value = toString($value);
    var index = 0;
    var dindex = 0;
    var found = false;
    var entriesLength = entries.length;
    var entry;
    while (index < entriesLength) {
      entry = entries[index++];
      if (found || entry.key === key) {
        found = true;
        $delete(this, entry.key);
      } else dindex++;
    }
    while (dindex < entriesLength) {
      entry = entries[dindex++];
      if (!(entry.key === key && entry.value === value)) append(this, entry.key, entry.value);
    }
  }, { enumerable: true, unsafe: true });
}


/***/ }),

/***/ 7566:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var defineBuiltIn = __webpack_require__(6840);
var uncurryThis = __webpack_require__(9504);
var toString = __webpack_require__(655);
var validateArgumentsLength = __webpack_require__(2812);

var $URLSearchParams = URLSearchParams;
var URLSearchParamsPrototype = $URLSearchParams.prototype;
var getAll = uncurryThis(URLSearchParamsPrototype.getAll);
var $has = uncurryThis(URLSearchParamsPrototype.has);
var params = new $URLSearchParams('a=1');

// `undefined` case is a Chromium 117 bug
// https://bugs.chromium.org/p/v8/issues/detail?id=14222
if (params.has('a', 2) || !params.has('a', undefined)) {
  defineBuiltIn(URLSearchParamsPrototype, 'has', function has(name /* , value */) {
    var length = arguments.length;
    var $value = length < 2 ? undefined : arguments[1];
    if (length && $value === undefined) return $has(this, name);
    var values = getAll(this, name); // also validates `this`
    validateArgumentsLength(length, 1);
    var value = toString($value);
    var index = 0;
    while (index < values.length) {
      if (values[index++] === value) return true;
    } return false;
  }, { enumerable: true, unsafe: true });
}


/***/ }),

/***/ 8408:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove this module from `core-js@4` since it's replaced to module below
__webpack_require__(8406);


/***/ }),

/***/ 8721:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


var DESCRIPTORS = __webpack_require__(3724);
var uncurryThis = __webpack_require__(9504);
var defineBuiltInAccessor = __webpack_require__(2106);

var URLSearchParamsPrototype = URLSearchParams.prototype;
var forEach = uncurryThis(URLSearchParamsPrototype.forEach);

// `URLSearchParams.prototype.size` getter
// https://github.com/whatwg/url/pull/734
if (DESCRIPTORS && !('size' in URLSearchParamsPrototype)) {
  defineBuiltInAccessor(URLSearchParamsPrototype, 'size', {
    get: function size() {
      var count = 0;
      forEach(this, function () { count++; });
      return count;
    },
    configurable: true,
    enumerable: true
  });
}


/***/ }),

/***/ 5806:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: in core-js@4, move /modules/ dependencies to public entries for better optimization by tools like `preset-env`
__webpack_require__(7764);
var $ = __webpack_require__(6518);
var DESCRIPTORS = __webpack_require__(3724);
var USE_NATIVE_URL = __webpack_require__(7416);
var global = __webpack_require__(4475);
var bind = __webpack_require__(6080);
var uncurryThis = __webpack_require__(9504);
var defineBuiltIn = __webpack_require__(6840);
var defineBuiltInAccessor = __webpack_require__(2106);
var anInstance = __webpack_require__(679);
var hasOwn = __webpack_require__(9297);
var assign = __webpack_require__(4213);
var arrayFrom = __webpack_require__(7916);
var arraySlice = __webpack_require__(7680);
var codeAt = (__webpack_require__(8183).codeAt);
var toASCII = __webpack_require__(6098);
var $toString = __webpack_require__(655);
var setToStringTag = __webpack_require__(687);
var validateArgumentsLength = __webpack_require__(2812);
var URLSearchParamsModule = __webpack_require__(8406);
var InternalStateModule = __webpack_require__(1181);

var setInternalState = InternalStateModule.set;
var getInternalURLState = InternalStateModule.getterFor('URL');
var URLSearchParams = URLSearchParamsModule.URLSearchParams;
var getInternalSearchParamsState = URLSearchParamsModule.getState;

var NativeURL = global.URL;
var TypeError = global.TypeError;
var parseInt = global.parseInt;
var floor = Math.floor;
var pow = Math.pow;
var charAt = uncurryThis(''.charAt);
var exec = uncurryThis(/./.exec);
var join = uncurryThis([].join);
var numberToString = uncurryThis(1.0.toString);
var pop = uncurryThis([].pop);
var push = uncurryThis([].push);
var replace = uncurryThis(''.replace);
var shift = uncurryThis([].shift);
var split = uncurryThis(''.split);
var stringSlice = uncurryThis(''.slice);
var toLowerCase = uncurryThis(''.toLowerCase);
var unshift = uncurryThis([].unshift);

var INVALID_AUTHORITY = 'Invalid authority';
var INVALID_SCHEME = 'Invalid scheme';
var INVALID_HOST = 'Invalid host';
var INVALID_PORT = 'Invalid port';

var ALPHA = /[a-z]/i;
// eslint-disable-next-line regexp/no-obscure-range -- safe
var ALPHANUMERIC = /[\d+-.a-z]/i;
var DIGIT = /\d/;
var HEX_START = /^0x/i;
var OCT = /^[0-7]+$/;
var DEC = /^\d+$/;
var HEX = /^[\da-f]+$/i;
/* eslint-disable regexp/no-control-character -- safe */
var FORBIDDEN_HOST_CODE_POINT = /[\0\t\n\r #%/:<>?@[\\\]^|]/;
var FORBIDDEN_HOST_CODE_POINT_EXCLUDING_PERCENT = /[\0\t\n\r #/:<>?@[\\\]^|]/;
var LEADING_C0_CONTROL_OR_SPACE = /^[\u0000-\u0020]+/;
var TRAILING_C0_CONTROL_OR_SPACE = /(^|[^\u0000-\u0020])[\u0000-\u0020]+$/;
var TAB_AND_NEW_LINE = /[\t\n\r]/g;
/* eslint-enable regexp/no-control-character -- safe */
var EOF;

// https://url.spec.whatwg.org/#ipv4-number-parser
var parseIPv4 = function (input) {
  var parts = split(input, '.');
  var partsLength, numbers, index, part, radix, number, ipv4;
  if (parts.length && parts[parts.length - 1] === '') {
    parts.length--;
  }
  partsLength = parts.length;
  if (partsLength > 4) return input;
  numbers = [];
  for (index = 0; index < partsLength; index++) {
    part = parts[index];
    if (part === '') return input;
    radix = 10;
    if (part.length > 1 && charAt(part, 0) === '0') {
      radix = exec(HEX_START, part) ? 16 : 8;
      part = stringSlice(part, radix === 8 ? 1 : 2);
    }
    if (part === '') {
      number = 0;
    } else {
      if (!exec(radix === 10 ? DEC : radix === 8 ? OCT : HEX, part)) return input;
      number = parseInt(part, radix);
    }
    push(numbers, number);
  }
  for (index = 0; index < partsLength; index++) {
    number = numbers[index];
    if (index === partsLength - 1) {
      if (number >= pow(256, 5 - partsLength)) return null;
    } else if (number > 255) return null;
  }
  ipv4 = pop(numbers);
  for (index = 0; index < numbers.length; index++) {
    ipv4 += numbers[index] * pow(256, 3 - index);
  }
  return ipv4;
};

// https://url.spec.whatwg.org/#concept-ipv6-parser
// eslint-disable-next-line max-statements -- TODO
var parseIPv6 = function (input) {
  var address = [0, 0, 0, 0, 0, 0, 0, 0];
  var pieceIndex = 0;
  var compress = null;
  var pointer = 0;
  var value, length, numbersSeen, ipv4Piece, number, swaps, swap;

  var chr = function () {
    return charAt(input, pointer);
  };

  if (chr() === ':') {
    if (charAt(input, 1) !== ':') return;
    pointer += 2;
    pieceIndex++;
    compress = pieceIndex;
  }
  while (chr()) {
    if (pieceIndex === 8) return;
    if (chr() === ':') {
      if (compress !== null) return;
      pointer++;
      pieceIndex++;
      compress = pieceIndex;
      continue;
    }
    value = length = 0;
    while (length < 4 && exec(HEX, chr())) {
      value = value * 16 + parseInt(chr(), 16);
      pointer++;
      length++;
    }
    if (chr() === '.') {
      if (length === 0) return;
      pointer -= length;
      if (pieceIndex > 6) return;
      numbersSeen = 0;
      while (chr()) {
        ipv4Piece = null;
        if (numbersSeen > 0) {
          if (chr() === '.' && numbersSeen < 4) pointer++;
          else return;
        }
        if (!exec(DIGIT, chr())) return;
        while (exec(DIGIT, chr())) {
          number = parseInt(chr(), 10);
          if (ipv4Piece === null) ipv4Piece = number;
          else if (ipv4Piece === 0) return;
          else ipv4Piece = ipv4Piece * 10 + number;
          if (ipv4Piece > 255) return;
          pointer++;
        }
        address[pieceIndex] = address[pieceIndex] * 256 + ipv4Piece;
        numbersSeen++;
        if (numbersSeen === 2 || numbersSeen === 4) pieceIndex++;
      }
      if (numbersSeen !== 4) return;
      break;
    } else if (chr() === ':') {
      pointer++;
      if (!chr()) return;
    } else if (chr()) return;
    address[pieceIndex++] = value;
  }
  if (compress !== null) {
    swaps = pieceIndex - compress;
    pieceIndex = 7;
    while (pieceIndex !== 0 && swaps > 0) {
      swap = address[pieceIndex];
      address[pieceIndex--] = address[compress + swaps - 1];
      address[compress + --swaps] = swap;
    }
  } else if (pieceIndex !== 8) return;
  return address;
};

var findLongestZeroSequence = function (ipv6) {
  var maxIndex = null;
  var maxLength = 1;
  var currStart = null;
  var currLength = 0;
  var index = 0;
  for (; index < 8; index++) {
    if (ipv6[index] !== 0) {
      if (currLength > maxLength) {
        maxIndex = currStart;
        maxLength = currLength;
      }
      currStart = null;
      currLength = 0;
    } else {
      if (currStart === null) currStart = index;
      ++currLength;
    }
  }
  if (currLength > maxLength) {
    maxIndex = currStart;
    maxLength = currLength;
  }
  return maxIndex;
};

// https://url.spec.whatwg.org/#host-serializing
var serializeHost = function (host) {
  var result, index, compress, ignore0;
  // ipv4
  if (typeof host == 'number') {
    result = [];
    for (index = 0; index < 4; index++) {
      unshift(result, host % 256);
      host = floor(host / 256);
    } return join(result, '.');
  // ipv6
  } else if (typeof host == 'object') {
    result = '';
    compress = findLongestZeroSequence(host);
    for (index = 0; index < 8; index++) {
      if (ignore0 && host[index] === 0) continue;
      if (ignore0) ignore0 = false;
      if (compress === index) {
        result += index ? ':' : '::';
        ignore0 = true;
      } else {
        result += numberToString(host[index], 16);
        if (index < 7) result += ':';
      }
    }
    return '[' + result + ']';
  } return host;
};

var C0ControlPercentEncodeSet = {};
var fragmentPercentEncodeSet = assign({}, C0ControlPercentEncodeSet, {
  ' ': 1, '"': 1, '<': 1, '>': 1, '`': 1
});
var pathPercentEncodeSet = assign({}, fragmentPercentEncodeSet, {
  '#': 1, '?': 1, '{': 1, '}': 1
});
var userinfoPercentEncodeSet = assign({}, pathPercentEncodeSet, {
  '/': 1, ':': 1, ';': 1, '=': 1, '@': 1, '[': 1, '\\': 1, ']': 1, '^': 1, '|': 1
});

var percentEncode = function (chr, set) {
  var code = codeAt(chr, 0);
  return code > 0x20 && code < 0x7F && !hasOwn(set, chr) ? chr : encodeURIComponent(chr);
};

// https://url.spec.whatwg.org/#special-scheme
var specialSchemes = {
  ftp: 21,
  file: null,
  http: 80,
  https: 443,
  ws: 80,
  wss: 443
};

// https://url.spec.whatwg.org/#windows-drive-letter
var isWindowsDriveLetter = function (string, normalized) {
  var second;
  return string.length === 2 && exec(ALPHA, charAt(string, 0))
    && ((second = charAt(string, 1)) === ':' || (!normalized && second === '|'));
};

// https://url.spec.whatwg.org/#start-with-a-windows-drive-letter
var startsWithWindowsDriveLetter = function (string) {
  var third;
  return string.length > 1 && isWindowsDriveLetter(stringSlice(string, 0, 2)) && (
    string.length === 2 ||
    ((third = charAt(string, 2)) === '/' || third === '\\' || third === '?' || third === '#')
  );
};

// https://url.spec.whatwg.org/#single-dot-path-segment
var isSingleDot = function (segment) {
  return segment === '.' || toLowerCase(segment) === '%2e';
};

// https://url.spec.whatwg.org/#double-dot-path-segment
var isDoubleDot = function (segment) {
  segment = toLowerCase(segment);
  return segment === '..' || segment === '%2e.' || segment === '.%2e' || segment === '%2e%2e';
};

// States:
var SCHEME_START = {};
var SCHEME = {};
var NO_SCHEME = {};
var SPECIAL_RELATIVE_OR_AUTHORITY = {};
var PATH_OR_AUTHORITY = {};
var RELATIVE = {};
var RELATIVE_SLASH = {};
var SPECIAL_AUTHORITY_SLASHES = {};
var SPECIAL_AUTHORITY_IGNORE_SLASHES = {};
var AUTHORITY = {};
var HOST = {};
var HOSTNAME = {};
var PORT = {};
var FILE = {};
var FILE_SLASH = {};
var FILE_HOST = {};
var PATH_START = {};
var PATH = {};
var CANNOT_BE_A_BASE_URL_PATH = {};
var QUERY = {};
var FRAGMENT = {};

var URLState = function (url, isBase, base) {
  var urlString = $toString(url);
  var baseState, failure, searchParams;
  if (isBase) {
    failure = this.parse(urlString);
    if (failure) throw new TypeError(failure);
    this.searchParams = null;
  } else {
    if (base !== undefined) baseState = new URLState(base, true);
    failure = this.parse(urlString, null, baseState);
    if (failure) throw new TypeError(failure);
    searchParams = getInternalSearchParamsState(new URLSearchParams());
    searchParams.bindURL(this);
    this.searchParams = searchParams;
  }
};

URLState.prototype = {
  type: 'URL',
  // https://url.spec.whatwg.org/#url-parsing
  // eslint-disable-next-line max-statements -- TODO
  parse: function (input, stateOverride, base) {
    var url = this;
    var state = stateOverride || SCHEME_START;
    var pointer = 0;
    var buffer = '';
    var seenAt = false;
    var seenBracket = false;
    var seenPasswordToken = false;
    var codePoints, chr, bufferCodePoints, failure;

    input = $toString(input);

    if (!stateOverride) {
      url.scheme = '';
      url.username = '';
      url.password = '';
      url.host = null;
      url.port = null;
      url.path = [];
      url.query = null;
      url.fragment = null;
      url.cannotBeABaseURL = false;
      input = replace(input, LEADING_C0_CONTROL_OR_SPACE, '');
      input = replace(input, TRAILING_C0_CONTROL_OR_SPACE, '$1');
    }

    input = replace(input, TAB_AND_NEW_LINE, '');

    codePoints = arrayFrom(input);

    while (pointer <= codePoints.length) {
      chr = codePoints[pointer];
      switch (state) {
        case SCHEME_START:
          if (chr && exec(ALPHA, chr)) {
            buffer += toLowerCase(chr);
            state = SCHEME;
          } else if (!stateOverride) {
            state = NO_SCHEME;
            continue;
          } else return INVALID_SCHEME;
          break;

        case SCHEME:
          if (chr && (exec(ALPHANUMERIC, chr) || chr === '+' || chr === '-' || chr === '.')) {
            buffer += toLowerCase(chr);
          } else if (chr === ':') {
            if (stateOverride && (
              (url.isSpecial() !== hasOwn(specialSchemes, buffer)) ||
              (buffer === 'file' && (url.includesCredentials() || url.port !== null)) ||
              (url.scheme === 'file' && !url.host)
            )) return;
            url.scheme = buffer;
            if (stateOverride) {
              if (url.isSpecial() && specialSchemes[url.scheme] === url.port) url.port = null;
              return;
            }
            buffer = '';
            if (url.scheme === 'file') {
              state = FILE;
            } else if (url.isSpecial() && base && base.scheme === url.scheme) {
              state = SPECIAL_RELATIVE_OR_AUTHORITY;
            } else if (url.isSpecial()) {
              state = SPECIAL_AUTHORITY_SLASHES;
            } else if (codePoints[pointer + 1] === '/') {
              state = PATH_OR_AUTHORITY;
              pointer++;
            } else {
              url.cannotBeABaseURL = true;
              push(url.path, '');
              state = CANNOT_BE_A_BASE_URL_PATH;
            }
          } else if (!stateOverride) {
            buffer = '';
            state = NO_SCHEME;
            pointer = 0;
            continue;
          } else return INVALID_SCHEME;
          break;

        case NO_SCHEME:
          if (!base || (base.cannotBeABaseURL && chr !== '#')) return INVALID_SCHEME;
          if (base.cannotBeABaseURL && chr === '#') {
            url.scheme = base.scheme;
            url.path = arraySlice(base.path);
            url.query = base.query;
            url.fragment = '';
            url.cannotBeABaseURL = true;
            state = FRAGMENT;
            break;
          }
          state = base.scheme === 'file' ? FILE : RELATIVE;
          continue;

        case SPECIAL_RELATIVE_OR_AUTHORITY:
          if (chr === '/' && codePoints[pointer + 1] === '/') {
            state = SPECIAL_AUTHORITY_IGNORE_SLASHES;
            pointer++;
          } else {
            state = RELATIVE;
            continue;
          } break;

        case PATH_OR_AUTHORITY:
          if (chr === '/') {
            state = AUTHORITY;
            break;
          } else {
            state = PATH;
            continue;
          }

        case RELATIVE:
          url.scheme = base.scheme;
          if (chr === EOF) {
            url.username = base.username;
            url.password = base.password;
            url.host = base.host;
            url.port = base.port;
            url.path = arraySlice(base.path);
            url.query = base.query;
          } else if (chr === '/' || (chr === '\\' && url.isSpecial())) {
            state = RELATIVE_SLASH;
          } else if (chr === '?') {
            url.username = base.username;
            url.password = base.password;
            url.host = base.host;
            url.port = base.port;
            url.path = arraySlice(base.path);
            url.query = '';
            state = QUERY;
          } else if (chr === '#') {
            url.username = base.username;
            url.password = base.password;
            url.host = base.host;
            url.port = base.port;
            url.path = arraySlice(base.path);
            url.query = base.query;
            url.fragment = '';
            state = FRAGMENT;
          } else {
            url.username = base.username;
            url.password = base.password;
            url.host = base.host;
            url.port = base.port;
            url.path = arraySlice(base.path);
            url.path.length--;
            state = PATH;
            continue;
          } break;

        case RELATIVE_SLASH:
          if (url.isSpecial() && (chr === '/' || chr === '\\')) {
            state = SPECIAL_AUTHORITY_IGNORE_SLASHES;
          } else if (chr === '/') {
            state = AUTHORITY;
          } else {
            url.username = base.username;
            url.password = base.password;
            url.host = base.host;
            url.port = base.port;
            state = PATH;
            continue;
          } break;

        case SPECIAL_AUTHORITY_SLASHES:
          state = SPECIAL_AUTHORITY_IGNORE_SLASHES;
          if (chr !== '/' || charAt(buffer, pointer + 1) !== '/') continue;
          pointer++;
          break;

        case SPECIAL_AUTHORITY_IGNORE_SLASHES:
          if (chr !== '/' && chr !== '\\') {
            state = AUTHORITY;
            continue;
          } break;

        case AUTHORITY:
          if (chr === '@') {
            if (seenAt) buffer = '%40' + buffer;
            seenAt = true;
            bufferCodePoints = arrayFrom(buffer);
            for (var i = 0; i < bufferCodePoints.length; i++) {
              var codePoint = bufferCodePoints[i];
              if (codePoint === ':' && !seenPasswordToken) {
                seenPasswordToken = true;
                continue;
              }
              var encodedCodePoints = percentEncode(codePoint, userinfoPercentEncodeSet);
              if (seenPasswordToken) url.password += encodedCodePoints;
              else url.username += encodedCodePoints;
            }
            buffer = '';
          } else if (
            chr === EOF || chr === '/' || chr === '?' || chr === '#' ||
            (chr === '\\' && url.isSpecial())
          ) {
            if (seenAt && buffer === '') return INVALID_AUTHORITY;
            pointer -= arrayFrom(buffer).length + 1;
            buffer = '';
            state = HOST;
          } else buffer += chr;
          break;

        case HOST:
        case HOSTNAME:
          if (stateOverride && url.scheme === 'file') {
            state = FILE_HOST;
            continue;
          } else if (chr === ':' && !seenBracket) {
            if (buffer === '') return INVALID_HOST;
            failure = url.parseHost(buffer);
            if (failure) return failure;
            buffer = '';
            state = PORT;
            if (stateOverride === HOSTNAME) return;
          } else if (
            chr === EOF || chr === '/' || chr === '?' || chr === '#' ||
            (chr === '\\' && url.isSpecial())
          ) {
            if (url.isSpecial() && buffer === '') return INVALID_HOST;
            if (stateOverride && buffer === '' && (url.includesCredentials() || url.port !== null)) return;
            failure = url.parseHost(buffer);
            if (failure) return failure;
            buffer = '';
            state = PATH_START;
            if (stateOverride) return;
            continue;
          } else {
            if (chr === '[') seenBracket = true;
            else if (chr === ']') seenBracket = false;
            buffer += chr;
          } break;

        case PORT:
          if (exec(DIGIT, chr)) {
            buffer += chr;
          } else if (
            chr === EOF || chr === '/' || chr === '?' || chr === '#' ||
            (chr === '\\' && url.isSpecial()) ||
            stateOverride
          ) {
            if (buffer !== '') {
              var port = parseInt(buffer, 10);
              if (port > 0xFFFF) return INVALID_PORT;
              url.port = (url.isSpecial() && port === specialSchemes[url.scheme]) ? null : port;
              buffer = '';
            }
            if (stateOverride) return;
            state = PATH_START;
            continue;
          } else return INVALID_PORT;
          break;

        case FILE:
          url.scheme = 'file';
          if (chr === '/' || chr === '\\') state = FILE_SLASH;
          else if (base && base.scheme === 'file') {
            switch (chr) {
              case EOF:
                url.host = base.host;
                url.path = arraySlice(base.path);
                url.query = base.query;
                break;
              case '?':
                url.host = base.host;
                url.path = arraySlice(base.path);
                url.query = '';
                state = QUERY;
                break;
              case '#':
                url.host = base.host;
                url.path = arraySlice(base.path);
                url.query = base.query;
                url.fragment = '';
                state = FRAGMENT;
                break;
              default:
                if (!startsWithWindowsDriveLetter(join(arraySlice(codePoints, pointer), ''))) {
                  url.host = base.host;
                  url.path = arraySlice(base.path);
                  url.shortenPath();
                }
                state = PATH;
                continue;
            }
          } else {
            state = PATH;
            continue;
          } break;

        case FILE_SLASH:
          if (chr === '/' || chr === '\\') {
            state = FILE_HOST;
            break;
          }
          if (base && base.scheme === 'file' && !startsWithWindowsDriveLetter(join(arraySlice(codePoints, pointer), ''))) {
            if (isWindowsDriveLetter(base.path[0], true)) push(url.path, base.path[0]);
            else url.host = base.host;
          }
          state = PATH;
          continue;

        case FILE_HOST:
          if (chr === EOF || chr === '/' || chr === '\\' || chr === '?' || chr === '#') {
            if (!stateOverride && isWindowsDriveLetter(buffer)) {
              state = PATH;
            } else if (buffer === '') {
              url.host = '';
              if (stateOverride) return;
              state = PATH_START;
            } else {
              failure = url.parseHost(buffer);
              if (failure) return failure;
              if (url.host === 'localhost') url.host = '';
              if (stateOverride) return;
              buffer = '';
              state = PATH_START;
            } continue;
          } else buffer += chr;
          break;

        case PATH_START:
          if (url.isSpecial()) {
            state = PATH;
            if (chr !== '/' && chr !== '\\') continue;
          } else if (!stateOverride && chr === '?') {
            url.query = '';
            state = QUERY;
          } else if (!stateOverride && chr === '#') {
            url.fragment = '';
            state = FRAGMENT;
          } else if (chr !== EOF) {
            state = PATH;
            if (chr !== '/') continue;
          } break;

        case PATH:
          if (
            chr === EOF || chr === '/' ||
            (chr === '\\' && url.isSpecial()) ||
            (!stateOverride && (chr === '?' || chr === '#'))
          ) {
            if (isDoubleDot(buffer)) {
              url.shortenPath();
              if (chr !== '/' && !(chr === '\\' && url.isSpecial())) {
                push(url.path, '');
              }
            } else if (isSingleDot(buffer)) {
              if (chr !== '/' && !(chr === '\\' && url.isSpecial())) {
                push(url.path, '');
              }
            } else {
              if (url.scheme === 'file' && !url.path.length && isWindowsDriveLetter(buffer)) {
                if (url.host) url.host = '';
                buffer = charAt(buffer, 0) + ':'; // normalize windows drive letter
              }
              push(url.path, buffer);
            }
            buffer = '';
            if (url.scheme === 'file' && (chr === EOF || chr === '?' || chr === '#')) {
              while (url.path.length > 1 && url.path[0] === '') {
                shift(url.path);
              }
            }
            if (chr === '?') {
              url.query = '';
              state = QUERY;
            } else if (chr === '#') {
              url.fragment = '';
              state = FRAGMENT;
            }
          } else {
            buffer += percentEncode(chr, pathPercentEncodeSet);
          } break;

        case CANNOT_BE_A_BASE_URL_PATH:
          if (chr === '?') {
            url.query = '';
            state = QUERY;
          } else if (chr === '#') {
            url.fragment = '';
            state = FRAGMENT;
          } else if (chr !== EOF) {
            url.path[0] += percentEncode(chr, C0ControlPercentEncodeSet);
          } break;

        case QUERY:
          if (!stateOverride && chr === '#') {
            url.fragment = '';
            state = FRAGMENT;
          } else if (chr !== EOF) {
            if (chr === "'" && url.isSpecial()) url.query += '%27';
            else if (chr === '#') url.query += '%23';
            else url.query += percentEncode(chr, C0ControlPercentEncodeSet);
          } break;

        case FRAGMENT:
          if (chr !== EOF) url.fragment += percentEncode(chr, fragmentPercentEncodeSet);
          break;
      }

      pointer++;
    }
  },
  // https://url.spec.whatwg.org/#host-parsing
  parseHost: function (input) {
    var result, codePoints, index;
    if (charAt(input, 0) === '[') {
      if (charAt(input, input.length - 1) !== ']') return INVALID_HOST;
      result = parseIPv6(stringSlice(input, 1, -1));
      if (!result) return INVALID_HOST;
      this.host = result;
    // opaque host
    } else if (!this.isSpecial()) {
      if (exec(FORBIDDEN_HOST_CODE_POINT_EXCLUDING_PERCENT, input)) return INVALID_HOST;
      result = '';
      codePoints = arrayFrom(input);
      for (index = 0; index < codePoints.length; index++) {
        result += percentEncode(codePoints[index], C0ControlPercentEncodeSet);
      }
      this.host = result;
    } else {
      input = toASCII(input);
      if (exec(FORBIDDEN_HOST_CODE_POINT, input)) return INVALID_HOST;
      result = parseIPv4(input);
      if (result === null) return INVALID_HOST;
      this.host = result;
    }
  },
  // https://url.spec.whatwg.org/#cannot-have-a-username-password-port
  cannotHaveUsernamePasswordPort: function () {
    return !this.host || this.cannotBeABaseURL || this.scheme === 'file';
  },
  // https://url.spec.whatwg.org/#include-credentials
  includesCredentials: function () {
    return this.username !== '' || this.password !== '';
  },
  // https://url.spec.whatwg.org/#is-special
  isSpecial: function () {
    return hasOwn(specialSchemes, this.scheme);
  },
  // https://url.spec.whatwg.org/#shorten-a-urls-path
  shortenPath: function () {
    var path = this.path;
    var pathSize = path.length;
    if (pathSize && (this.scheme !== 'file' || pathSize !== 1 || !isWindowsDriveLetter(path[0], true))) {
      path.length--;
    }
  },
  // https://url.spec.whatwg.org/#concept-url-serializer
  serialize: function () {
    var url = this;
    var scheme = url.scheme;
    var username = url.username;
    var password = url.password;
    var host = url.host;
    var port = url.port;
    var path = url.path;
    var query = url.query;
    var fragment = url.fragment;
    var output = scheme + ':';
    if (host !== null) {
      output += '//';
      if (url.includesCredentials()) {
        output += username + (password ? ':' + password : '') + '@';
      }
      output += serializeHost(host);
      if (port !== null) output += ':' + port;
    } else if (scheme === 'file') output += '//';
    output += url.cannotBeABaseURL ? path[0] : path.length ? '/' + join(path, '/') : '';
    if (query !== null) output += '?' + query;
    if (fragment !== null) output += '#' + fragment;
    return output;
  },
  // https://url.spec.whatwg.org/#dom-url-href
  setHref: function (href) {
    var failure = this.parse(href);
    if (failure) throw new TypeError(failure);
    this.searchParams.update();
  },
  // https://url.spec.whatwg.org/#dom-url-origin
  getOrigin: function () {
    var scheme = this.scheme;
    var port = this.port;
    if (scheme === 'blob') try {
      return new URLConstructor(scheme.path[0]).origin;
    } catch (error) {
      return 'null';
    }
    if (scheme === 'file' || !this.isSpecial()) return 'null';
    return scheme + '://' + serializeHost(this.host) + (port !== null ? ':' + port : '');
  },
  // https://url.spec.whatwg.org/#dom-url-protocol
  getProtocol: function () {
    return this.scheme + ':';
  },
  setProtocol: function (protocol) {
    this.parse($toString(protocol) + ':', SCHEME_START);
  },
  // https://url.spec.whatwg.org/#dom-url-username
  getUsername: function () {
    return this.username;
  },
  setUsername: function (username) {
    var codePoints = arrayFrom($toString(username));
    if (this.cannotHaveUsernamePasswordPort()) return;
    this.username = '';
    for (var i = 0; i < codePoints.length; i++) {
      this.username += percentEncode(codePoints[i], userinfoPercentEncodeSet);
    }
  },
  // https://url.spec.whatwg.org/#dom-url-password
  getPassword: function () {
    return this.password;
  },
  setPassword: function (password) {
    var codePoints = arrayFrom($toString(password));
    if (this.cannotHaveUsernamePasswordPort()) return;
    this.password = '';
    for (var i = 0; i < codePoints.length; i++) {
      this.password += percentEncode(codePoints[i], userinfoPercentEncodeSet);
    }
  },
  // https://url.spec.whatwg.org/#dom-url-host
  getHost: function () {
    var host = this.host;
    var port = this.port;
    return host === null ? ''
      : port === null ? serializeHost(host)
      : serializeHost(host) + ':' + port;
  },
  setHost: function (host) {
    if (this.cannotBeABaseURL) return;
    this.parse(host, HOST);
  },
  // https://url.spec.whatwg.org/#dom-url-hostname
  getHostname: function () {
    var host = this.host;
    return host === null ? '' : serializeHost(host);
  },
  setHostname: function (hostname) {
    if (this.cannotBeABaseURL) return;
    this.parse(hostname, HOSTNAME);
  },
  // https://url.spec.whatwg.org/#dom-url-port
  getPort: function () {
    var port = this.port;
    return port === null ? '' : $toString(port);
  },
  setPort: function (port) {
    if (this.cannotHaveUsernamePasswordPort()) return;
    port = $toString(port);
    if (port === '') this.port = null;
    else this.parse(port, PORT);
  },
  // https://url.spec.whatwg.org/#dom-url-pathname
  getPathname: function () {
    var path = this.path;
    return this.cannotBeABaseURL ? path[0] : path.length ? '/' + join(path, '/') : '';
  },
  setPathname: function (pathname) {
    if (this.cannotBeABaseURL) return;
    this.path = [];
    this.parse(pathname, PATH_START);
  },
  // https://url.spec.whatwg.org/#dom-url-search
  getSearch: function () {
    var query = this.query;
    return query ? '?' + query : '';
  },
  setSearch: function (search) {
    search = $toString(search);
    if (search === '') {
      this.query = null;
    } else {
      if (charAt(search, 0) === '?') search = stringSlice(search, 1);
      this.query = '';
      this.parse(search, QUERY);
    }
    this.searchParams.update();
  },
  // https://url.spec.whatwg.org/#dom-url-searchparams
  getSearchParams: function () {
    return this.searchParams.facade;
  },
  // https://url.spec.whatwg.org/#dom-url-hash
  getHash: function () {
    var fragment = this.fragment;
    return fragment ? '#' + fragment : '';
  },
  setHash: function (hash) {
    hash = $toString(hash);
    if (hash === '') {
      this.fragment = null;
      return;
    }
    if (charAt(hash, 0) === '#') hash = stringSlice(hash, 1);
    this.fragment = '';
    this.parse(hash, FRAGMENT);
  },
  update: function () {
    this.query = this.searchParams.serialize() || null;
  }
};

// `URL` constructor
// https://url.spec.whatwg.org/#url-class
var URLConstructor = function URL(url /* , base */) {
  var that = anInstance(this, URLPrototype);
  var base = validateArgumentsLength(arguments.length, 1) > 1 ? arguments[1] : undefined;
  var state = setInternalState(that, new URLState(url, false, base));
  if (!DESCRIPTORS) {
    that.href = state.serialize();
    that.origin = state.getOrigin();
    that.protocol = state.getProtocol();
    that.username = state.getUsername();
    that.password = state.getPassword();
    that.host = state.getHost();
    that.hostname = state.getHostname();
    that.port = state.getPort();
    that.pathname = state.getPathname();
    that.search = state.getSearch();
    that.searchParams = state.getSearchParams();
    that.hash = state.getHash();
  }
};

var URLPrototype = URLConstructor.prototype;

var accessorDescriptor = function (getter, setter) {
  return {
    get: function () {
      return getInternalURLState(this)[getter]();
    },
    set: setter && function (value) {
      return getInternalURLState(this)[setter](value);
    },
    configurable: true,
    enumerable: true
  };
};

if (DESCRIPTORS) {
  // `URL.prototype.href` accessors pair
  // https://url.spec.whatwg.org/#dom-url-href
  defineBuiltInAccessor(URLPrototype, 'href', accessorDescriptor('serialize', 'setHref'));
  // `URL.prototype.origin` getter
  // https://url.spec.whatwg.org/#dom-url-origin
  defineBuiltInAccessor(URLPrototype, 'origin', accessorDescriptor('getOrigin'));
  // `URL.prototype.protocol` accessors pair
  // https://url.spec.whatwg.org/#dom-url-protocol
  defineBuiltInAccessor(URLPrototype, 'protocol', accessorDescriptor('getProtocol', 'setProtocol'));
  // `URL.prototype.username` accessors pair
  // https://url.spec.whatwg.org/#dom-url-username
  defineBuiltInAccessor(URLPrototype, 'username', accessorDescriptor('getUsername', 'setUsername'));
  // `URL.prototype.password` accessors pair
  // https://url.spec.whatwg.org/#dom-url-password
  defineBuiltInAccessor(URLPrototype, 'password', accessorDescriptor('getPassword', 'setPassword'));
  // `URL.prototype.host` accessors pair
  // https://url.spec.whatwg.org/#dom-url-host
  defineBuiltInAccessor(URLPrototype, 'host', accessorDescriptor('getHost', 'setHost'));
  // `URL.prototype.hostname` accessors pair
  // https://url.spec.whatwg.org/#dom-url-hostname
  defineBuiltInAccessor(URLPrototype, 'hostname', accessorDescriptor('getHostname', 'setHostname'));
  // `URL.prototype.port` accessors pair
  // https://url.spec.whatwg.org/#dom-url-port
  defineBuiltInAccessor(URLPrototype, 'port', accessorDescriptor('getPort', 'setPort'));
  // `URL.prototype.pathname` accessors pair
  // https://url.spec.whatwg.org/#dom-url-pathname
  defineBuiltInAccessor(URLPrototype, 'pathname', accessorDescriptor('getPathname', 'setPathname'));
  // `URL.prototype.search` accessors pair
  // https://url.spec.whatwg.org/#dom-url-search
  defineBuiltInAccessor(URLPrototype, 'search', accessorDescriptor('getSearch', 'setSearch'));
  // `URL.prototype.searchParams` getter
  // https://url.spec.whatwg.org/#dom-url-searchparams
  defineBuiltInAccessor(URLPrototype, 'searchParams', accessorDescriptor('getSearchParams'));
  // `URL.prototype.hash` accessors pair
  // https://url.spec.whatwg.org/#dom-url-hash
  defineBuiltInAccessor(URLPrototype, 'hash', accessorDescriptor('getHash', 'setHash'));
}

// `URL.prototype.toJSON` method
// https://url.spec.whatwg.org/#dom-url-tojson
defineBuiltIn(URLPrototype, 'toJSON', function toJSON() {
  return getInternalURLState(this).serialize();
}, { enumerable: true });

// `URL.prototype.toString` method
// https://url.spec.whatwg.org/#URL-stringification-behavior
defineBuiltIn(URLPrototype, 'toString', function toString() {
  return getInternalURLState(this).serialize();
}, { enumerable: true });

if (NativeURL) {
  var nativeCreateObjectURL = NativeURL.createObjectURL;
  var nativeRevokeObjectURL = NativeURL.revokeObjectURL;
  // `URL.createObjectURL` method
  // https://developer.mozilla.org/en-US/docs/Web/API/URL/createObjectURL
  if (nativeCreateObjectURL) defineBuiltIn(URLConstructor, 'createObjectURL', bind(nativeCreateObjectURL, NativeURL));
  // `URL.revokeObjectURL` method
  // https://developer.mozilla.org/en-US/docs/Web/API/URL/revokeObjectURL
  if (nativeRevokeObjectURL) defineBuiltIn(URLConstructor, 'revokeObjectURL', bind(nativeRevokeObjectURL, NativeURL));
}

setToStringTag(URLConstructor, 'URL');

$({ global: true, constructor: true, forced: !USE_NATIVE_URL, sham: !DESCRIPTORS }, {
  URL: URLConstructor
});


/***/ }),

/***/ 3296:
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {


// TODO: Remove this module from `core-js@4` since it's replaced to module below
__webpack_require__(5806);


/***/ }),

/***/ 9796:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {

/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   A: function() { return /* binding */ _arrayLikeToArray; }
/* harmony export */ });
function _arrayLikeToArray(arr, len) {
  if (len == null || len > arr.length) len = arr.length;
  for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
  return arr2;
}

/***/ }),

/***/ 1362:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {

/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   A: function() { return /* binding */ _asyncToGenerator; }
/* harmony export */ });
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6099);

function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
  try {
    var info = gen[key](arg);
    var value = info.value;
  } catch (error) {
    reject(error);
    return;
  }
  if (info.done) {
    resolve(value);
  } else {
    Promise.resolve(value).then(_next, _throw);
  }
}
function _asyncToGenerator(fn) {
  return function () {
    var self = this,
      args = arguments;
    return new Promise(function (resolve, reject) {
      var gen = fn.apply(self, args);
      function _next(value) {
        asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);
      }
      function _throw(err) {
        asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);
      }
      _next(undefined);
    });
  };
}

/***/ }),

/***/ 2934:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {


// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  A: function() { return /* binding */ _callSuper; }
});

// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.to-string.js
var es_object_to_string = __webpack_require__(6099);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.reflect.construct.js
var es_reflect_construct = __webpack_require__(825);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.reflect.to-string-tag.js
var es_reflect_to_string_tag = __webpack_require__(5472);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js
var getPrototypeOf = __webpack_require__(6643);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/isNativeReflectConstruct.js



function _isNativeReflectConstruct() {
  try {
    var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
  } catch (t) {}
  return (_isNativeReflectConstruct = function _isNativeReflectConstruct() {
    return !!t;
  })();
}
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.error.cause.js
var es_error_cause = __webpack_require__(6280);
// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/typeof.js
var esm_typeof = __webpack_require__(7089);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js

function _assertThisInitialized(self) {
  if (self === void 0) {
    throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
  }
  return self;
}
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js



function _possibleConstructorReturn(self, call) {
  if (call && ((0,esm_typeof/* default */.A)(call) === "object" || typeof call === "function")) {
    return call;
  } else if (call !== void 0) {
    throw new TypeError("Derived constructors may only return object or undefined");
  }
  return _assertThisInitialized(self);
}
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/callSuper.js






function _callSuper(t, o, e) {
  return o = (0,getPrototypeOf/* default */.A)(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0,getPrototypeOf/* default */.A)(t).constructor) : o.apply(t, e));
}

/***/ }),

/***/ 1512:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {

/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   A: function() { return /* binding */ _classCallCheck; }
/* harmony export */ });
/* harmony import */ var core_js_modules_es_error_cause_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6280);

function _classCallCheck(instance, Constructor) {
  if (!(instance instanceof Constructor)) {
    throw new TypeError("Cannot call a class as a function");
  }
}

/***/ }),

/***/ 5629:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {


// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  A: function() { return /* binding */ _createClass; }
});

// EXTERNAL MODULE: ./node_modules/@babel/runtime/helpers/esm/typeof.js
var esm_typeof = __webpack_require__(7089);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.js
var es_symbol = __webpack_require__(2675);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.description.js
var es_symbol_description = __webpack_require__(9463);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.symbol.to-primitive.js
var es_symbol_to_primitive = __webpack_require__(5700);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.error.cause.js
var es_error_cause = __webpack_require__(6280);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.date.to-primitive.js
var es_date_to_primitive = __webpack_require__(9572);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.number.constructor.js
var es_number_constructor = __webpack_require__(2892);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.to-string.js
var es_object_to_string = __webpack_require__(6099);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/toPrimitive.js








function toPrimitive(t, r) {
  if ("object" != (0,esm_typeof/* default */.A)(t) || !t) return t;
  var e = t[Symbol.toPrimitive];
  if (void 0 !== e) {
    var i = e.call(t, r || "default");
    if ("object" != (0,esm_typeof/* default */.A)(i)) return i;
    throw new TypeError("@@toPrimitive must return a primitive value.");
  }
  return ("string" === r ? String : Number)(t);
}
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/toPropertyKey.js


function toPropertyKey(t) {
  var i = toPrimitive(t, "string");
  return "symbol" == (0,esm_typeof/* default */.A)(i) ? i : String(i);
}
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/createClass.js

function _defineProperties(target, props) {
  for (var i = 0; i < props.length; i++) {
    var descriptor = props[i];
    descriptor.enumerable = descriptor.enumerable || false;
    descriptor.configurable = true;
    if ("value" in descriptor) descriptor.writable = true;
    Object.defineProperty(target, toPropertyKey(descriptor.key), descriptor);
  }
}
function _createClass(Constructor, protoProps, staticProps) {
  if (protoProps) _defineProperties(Constructor.prototype, protoProps);
  if (staticProps) _defineProperties(Constructor, staticProps);
  Object.defineProperty(Constructor, "prototype", {
    writable: false
  });
  return Constructor;
}

/***/ }),

/***/ 6643:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {

/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   A: function() { return /* binding */ _getPrototypeOf; }
/* harmony export */ });
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(875);
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(287);


function _getPrototypeOf(o) {
  _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) {
    return o.__proto__ || Object.getPrototypeOf(o);
  };
  return _getPrototypeOf(o);
}

/***/ }),

/***/ 6229:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {


// EXPORTS
__webpack_require__.d(__webpack_exports__, {
  A: function() { return /* binding */ _inherits; }
});

// EXTERNAL MODULE: ./node_modules/core-js/modules/es.error.cause.js
var es_error_cause = __webpack_require__(6280);
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.set-prototype-of.js
var es_object_set_prototype_of = __webpack_require__(287);
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js

function _setPrototypeOf(o, p) {
  _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
    o.__proto__ = p;
    return o;
  };
  return _setPrototypeOf(o, p);
}
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/inherits.js


function _inherits(subClass, superClass) {
  if (typeof superClass !== "function" && superClass !== null) {
    throw new TypeError("Super expression must either be null or a function");
  }
  subClass.prototype = Object.create(superClass && superClass.prototype, {
    constructor: {
      value: subClass,
      writable: true,
      configurable: true
    }
  });
  Object.defineProperty(subClass, "prototype", {
    writable: false
  });
  if (superClass) _setPrototypeOf(subClass, superClass);
}

/***/ }),

/***/ 2946:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {

/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   A: function() { return /* binding */ _regeneratorRuntime; }
/* harmony export */ });
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2675);
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(9463);
/* harmony import */ var core_js_modules_es_symbol_async_iterator_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6412);
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2259);
/* harmony import */ var core_js_modules_es_symbol_to_string_tag_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(8125);
/* harmony import */ var core_js_modules_es_error_cause_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6280);
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(4114);
/* harmony import */ var core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(4782);
/* harmony import */ var core_js_modules_es_json_to_string_tag_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(4731);
/* harmony import */ var core_js_modules_es_math_to_string_tag_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(479);
/* harmony import */ var core_js_modules_es_object_get_prototype_of_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(875);
/* harmony import */ var core_js_modules_es_object_set_prototype_of_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(287);
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(6099);
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(7764);
/* harmony import */ var core_js_modules_web_dom_collections_for_each_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(3500);
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(2953);
/* harmony import */ var _typeof_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(7089);

















function _regeneratorRuntime() {
  "use strict";

  /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
  _regeneratorRuntime = function _regeneratorRuntime() {
    return e;
  };
  var t,
    e = {},
    r = Object.prototype,
    n = r.hasOwnProperty,
    o = Object.defineProperty || function (t, e, r) {
      t[e] = r.value;
    },
    i = "function" == typeof Symbol ? Symbol : {},
    a = i.iterator || "@@iterator",
    c = i.asyncIterator || "@@asyncIterator",
    u = i.toStringTag || "@@toStringTag";
  function define(t, e, r) {
    return Object.defineProperty(t, e, {
      value: r,
      enumerable: !0,
      configurable: !0,
      writable: !0
    }), t[e];
  }
  try {
    define({}, "");
  } catch (t) {
    define = function define(t, e, r) {
      return t[e] = r;
    };
  }
  function wrap(t, e, r, n) {
    var i = e && e.prototype instanceof Generator ? e : Generator,
      a = Object.create(i.prototype),
      c = new Context(n || []);
    return o(a, "_invoke", {
      value: makeInvokeMethod(t, r, c)
    }), a;
  }
  function tryCatch(t, e, r) {
    try {
      return {
        type: "normal",
        arg: t.call(e, r)
      };
    } catch (t) {
      return {
        type: "throw",
        arg: t
      };
    }
  }
  e.wrap = wrap;
  var h = "suspendedStart",
    l = "suspendedYield",
    f = "executing",
    s = "completed",
    y = {};
  function Generator() {}
  function GeneratorFunction() {}
  function GeneratorFunctionPrototype() {}
  var p = {};
  define(p, a, function () {
    return this;
  });
  var d = Object.getPrototypeOf,
    v = d && d(d(values([])));
  v && v !== r && n.call(v, a) && (p = v);
  var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p);
  function defineIteratorMethods(t) {
    ["next", "throw", "return"].forEach(function (e) {
      define(t, e, function (t) {
        return this._invoke(e, t);
      });
    });
  }
  function AsyncIterator(t, e) {
    function invoke(r, o, i, a) {
      var c = tryCatch(t[r], t, o);
      if ("throw" !== c.type) {
        var u = c.arg,
          h = u.value;
        return h && "object" == (0,_typeof_js__WEBPACK_IMPORTED_MODULE_16__/* ["default"] */ .A)(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) {
          invoke("next", t, i, a);
        }, function (t) {
          invoke("throw", t, i, a);
        }) : e.resolve(h).then(function (t) {
          u.value = t, i(u);
        }, function (t) {
          return invoke("throw", t, i, a);
        });
      }
      a(c.arg);
    }
    var r;
    o(this, "_invoke", {
      value: function value(t, n) {
        function callInvokeWithMethodAndArg() {
          return new e(function (e, r) {
            invoke(t, n, e, r);
          });
        }
        return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
      }
    });
  }
  function makeInvokeMethod(e, r, n) {
    var o = h;
    return function (i, a) {
      if (o === f) throw new Error("Generator is already running");
      if (o === s) {
        if ("throw" === i) throw a;
        return {
          value: t,
          done: !0
        };
      }
      for (n.method = i, n.arg = a;;) {
        var c = n.delegate;
        if (c) {
          var u = maybeInvokeDelegate(c, n);
          if (u) {
            if (u === y) continue;
            return u;
          }
        }
        if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
          if (o === h) throw o = s, n.arg;
          n.dispatchException(n.arg);
        } else "return" === n.method && n.abrupt("return", n.arg);
        o = f;
        var p = tryCatch(e, r, n);
        if ("normal" === p.type) {
          if (o = n.done ? s : l, p.arg === y) continue;
          return {
            value: p.arg,
            done: n.done
          };
        }
        "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
      }
    };
  }
  function maybeInvokeDelegate(e, r) {
    var n = r.method,
      o = e.iterator[n];
    if (o === t) return r.delegate = null, "throw" === n && e.iterator["return"] && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
    var i = tryCatch(o, e.iterator, r.arg);
    if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
    var a = i.arg;
    return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
  }
  function pushTryEntry(t) {
    var e = {
      tryLoc: t[0]
    };
    1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
  }
  function resetTryEntry(t) {
    var e = t.completion || {};
    e.type = "normal", delete e.arg, t.completion = e;
  }
  function Context(t) {
    this.tryEntries = [{
      tryLoc: "root"
    }], t.forEach(pushTryEntry, this), this.reset(!0);
  }
  function values(e) {
    if (e || "" === e) {
      var r = e[a];
      if (r) return r.call(e);
      if ("function" == typeof e.next) return e;
      if (!isNaN(e.length)) {
        var o = -1,
          i = function next() {
            for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
            return next.value = t, next.done = !0, next;
          };
        return i.next = i;
      }
    }
    throw new TypeError((0,_typeof_js__WEBPACK_IMPORTED_MODULE_16__/* ["default"] */ .A)(e) + " is not iterable");
  }
  return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
    value: GeneratorFunctionPrototype,
    configurable: !0
  }), o(GeneratorFunctionPrototype, "constructor", {
    value: GeneratorFunction,
    configurable: !0
  }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
    var e = "function" == typeof t && t.constructor;
    return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
  }, e.mark = function (t) {
    return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
  }, e.awrap = function (t) {
    return {
      __await: t
    };
  }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
    return this;
  }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
    void 0 === i && (i = Promise);
    var a = new AsyncIterator(wrap(t, r, n, o), i);
    return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
      return t.done ? t.value : a.next();
    });
  }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () {
    return this;
  }), define(g, "toString", function () {
    return "[object Generator]";
  }), e.keys = function (t) {
    var e = Object(t),
      r = [];
    for (var n in e) r.push(n);
    return r.reverse(), function next() {
      for (; r.length;) {
        var t = r.pop();
        if (t in e) return next.value = t, next.done = !1, next;
      }
      return next.done = !0, next;
    };
  }, e.values = values, Context.prototype = {
    constructor: Context,
    reset: function reset(e) {
      if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
    },
    stop: function stop() {
      this.done = !0;
      var t = this.tryEntries[0].completion;
      if ("throw" === t.type) throw t.arg;
      return this.rval;
    },
    dispatchException: function dispatchException(e) {
      if (this.done) throw e;
      var r = this;
      function handle(n, o) {
        return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
      }
      for (var o = this.tryEntries.length - 1; o >= 0; --o) {
        var i = this.tryEntries[o],
          a = i.completion;
        if ("root" === i.tryLoc) return handle("end");
        if (i.tryLoc <= this.prev) {
          var c = n.call(i, "catchLoc"),
            u = n.call(i, "finallyLoc");
          if (c && u) {
            if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
            if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
          } else if (c) {
            if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
          } else {
            if (!u) throw new Error("try statement without catch or finally");
            if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
          }
        }
      }
    },
    abrupt: function abrupt(t, e) {
      for (var r = this.tryEntries.length - 1; r >= 0; --r) {
        var o = this.tryEntries[r];
        if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
          var i = o;
          break;
        }
      }
      i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
      var a = i ? i.completion : {};
      return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
    },
    complete: function complete(t, e) {
      if ("throw" === t.type) throw t.arg;
      return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
    },
    finish: function finish(t) {
      for (var e = this.tryEntries.length - 1; e >= 0; --e) {
        var r = this.tryEntries[e];
        if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
      }
    },
    "catch": function _catch(t) {
      for (var e = this.tryEntries.length - 1; e >= 0; --e) {
        var r = this.tryEntries[e];
        if (r.tryLoc === t) {
          var n = r.completion;
          if ("throw" === n.type) {
            var o = n.arg;
            resetTryEntry(r);
          }
          return o;
        }
      }
      throw new Error("illegal catch attempt");
    },
    delegateYield: function delegateYield(e, r, n) {
      return this.delegate = {
        iterator: values(e),
        resultName: r,
        nextLoc: n
      }, "next" === this.method && (this.arg = t), y;
    }
  }, e;
}

/***/ }),

/***/ 7089:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {

/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   A: function() { return /* binding */ _typeof; }
/* harmony export */ });
/* harmony import */ var core_js_modules_es_symbol_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(2675);
/* harmony import */ var core_js_modules_es_symbol_description_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(9463);
/* harmony import */ var core_js_modules_es_symbol_iterator_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2259);
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6099);
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7764);
/* harmony import */ var core_js_modules_web_dom_collections_iterator_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2953);






function _typeof(o) {
  "@babel/helpers - typeof";

  return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
    return typeof o;
  } : function (o) {
    return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
  }, _typeof(o);
}

/***/ }),

/***/ 5417:
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {

/* harmony export */ __webpack_require__.d(__webpack_exports__, {
/* harmony export */   A: function() { return /* binding */ _unsupportedIterableToArray; }
/* harmony export */ });
/* harmony import */ var core_js_modules_es_array_from_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(3418);
/* harmony import */ var core_js_modules_es_array_slice_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(4782);
/* harmony import */ var core_js_modules_es_object_to_string_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6099);
/* harmony import */ var core_js_modules_es_regexp_exec_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7495);
/* harmony import */ var core_js_modules_es_regexp_test_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(906);
/* harmony import */ var core_js_modules_es_regexp_to_string_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8781);
/* harmony import */ var core_js_modules_es_string_iterator_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(7764);
/* harmony import */ var _arrayLikeToArray_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(9796);








function _unsupportedIterableToArray(o, minLen) {
  if (!o) return;
  if (typeof o === "string") return (0,_arrayLikeToArray_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A)(o, minLen);
  var n = Object.prototype.toString.call(o).slice(8, -1);
  if (n === "Object" && o.constructor) n = o.constructor.name;
  if (n === "Map" || n === "Set") return Array.from(o);
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return (0,_arrayLikeToArray_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A)(o, minLen);
}

/***/ })

/******/ 	});
/************************************************************************/
/******/ 	// The module cache
/******/ 	var __webpack_module_cache__ = {};
/******/ 	
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/ 		// Check if module is in cache
/******/ 		var cachedModule = __webpack_module_cache__[moduleId];
/******/ 		if (cachedModule !== undefined) {
/******/ 			return cachedModule.exports;
/******/ 		}
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = __webpack_module_cache__[moduleId] = {
/******/ 			// no module.id needed
/******/ 			// no module.loaded needed
/******/ 			exports: {}
/******/ 		};
/******/ 	
/******/ 		// Execute the module function
/******/ 		__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/ 	
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/ 	
/************************************************************************/
/******/ 	/* webpack/runtime/define property getters */
/******/ 	!function() {
/******/ 		// define getter functions for harmony exports
/******/ 		__webpack_require__.d = function(exports, definition) {
/******/ 			for(var key in definition) {
/******/ 				if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
/******/ 					Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
/******/ 				}
/******/ 			}
/******/ 		};
/******/ 	}();
/******/ 	
/******/ 	/* webpack/runtime/global */
/******/ 	!function() {
/******/ 		__webpack_require__.g = (function() {
/******/ 			if (typeof globalThis === 'object') return globalThis;
/******/ 			try {
/******/ 				return this || new Function('return this')();
/******/ 			} catch (e) {
/******/ 				if (typeof window === 'object') return window;
/******/ 			}
/******/ 		})();
/******/ 	}();
/******/ 	
/******/ 	/* webpack/runtime/hasOwnProperty shorthand */
/******/ 	!function() {
/******/ 		__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }
/******/ 	}();
/******/ 	
/******/ 	/* webpack/runtime/make namespace object */
/******/ 	!function() {
/******/ 		// define __esModule on exports
/******/ 		__webpack_require__.r = function(exports) {
/******/ 			if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ 				Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ 			}
/******/ 			Object.defineProperty(exports, '__esModule', { value: true });
/******/ 		};
/******/ 	}();
/******/ 	
/******/ 	/* webpack/runtime/publicPath */
/******/ 	!function() {
/******/ 		__webpack_require__.p = "";
/******/ 	}();
/******/ 	
/************************************************************************/
var __webpack_exports__ = {};
// This entry need to be wrapped in an IIFE because it need to be isolated against other modules in the chunk.
!function() {
// ESM COMPAT FLAG
__webpack_require__.r(__webpack_exports__);

;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js
/* eslint-disable no-var */
// This file is imported into lib/wc client bundles.

if (typeof window !== 'undefined') {
  var currentScript = window.document.currentScript
  if (false) { var getCurrentScript; }

  var src = currentScript && currentScript.src.match(/(.+\/)[^/]+\.js(\?.*)?$/)
  if (src) {
    __webpack_require__.p = src[1] // eslint-disable-line
  }
}

// Indicate to webpack that this file can be concatenated
/* harmony default export */ var setPublicPath = (null);

// EXTERNAL MODULE: ./src/components/chunk/index.js + 4 modules
var chunk = __webpack_require__(6218);
// EXTERNAL MODULE: ./src/components/chunk/index2.js + 2 modules
var index2 = __webpack_require__(3999);
// EXTERNAL MODULE: ./src/components/waifu-tips.js + 1 modules
var waifu_tips = __webpack_require__(5673);
;// CONCATENATED MODULE: ./src/components/index.js



;// CONCATENATED MODULE: ./node_modules/@vue/cli-service/lib/commands/build/entry-lib-no-default.js



}();
/******/ 	return __webpack_exports__;
/******/ })()
;
});